Skip to main content

License Activation

Activate your ModPageSpeed 2.0 license key on nginx and the Factory Worker.

ModPageSpeed 2.0 is licensed under the Business Source License 1.1 (BSL). The BSL is the legal enforcement mechanism. The Ed25519 license token system described on this page is a warn-only technical check — it does not block functionality. Running without a valid license key logs a warning on startup. Everything still works.

License Model

ModPageSpeed 2.0 uses a two-layer licensing approach:

  1. BSL 1.1 — The source code license. It defines what you may and may not do with the software. This is the binding legal agreement.
  2. Ed25519 license token — A cryptographic token that identifies you as a licensed customer. Both the nginx interceptor and the Factory Worker verify this token on startup. If the token is missing, invalid, or expired, the software logs a warning and continues operating normally.

The token is not DRM. It exists so the software can display your license status in the web console and logs.

Token Format

A license token is a single base64url-encoded string (no padding) containing:

  • A 64-byte Ed25519 signature
  • A JSON payload

The JSON payload contains:

FieldDescription
subCustomer email address
issIssuer (modpagespeed.com)
iatIssued-at timestamp (Unix epoch)
expExpiry timestamp (0 = no expiry)
planPlan name (e.g., pro)
sidSubscription ID (optional)
kidKey ID for key rotation (optional)

The token is verified against an Ed25519 public key embedded in the binary. Signature verification and expiry checks run once at startup.

Activating Your License

Both the nginx interceptor and the Factory Worker accept the license key. You should configure it on both components.

Set PAGESPEED_LICENSE_KEY in your environment:

export PAGESPEED_LICENSE_KEY="your-token-here"

For Docker Compose, add it to your .env file:

PAGESPEED_LICENSE_KEY=your-token-here

For Kubernetes, the Helm chart handles this via values.yaml:

licenseKey: "your-token-here"

Or reference an existing Kubernetes secret:

existingSecret: "my-license-secret"
existingSecretKey: "license-key"

Command-Line Flag

Pass the token directly to each binary:

# Factory Worker
factory_worker --license-key your-token-here --cache-path /data/cache.vol

# nginx module reads from the environment variable only

The environment variable approach is preferred because it works for both components and avoids exposing the token in process listings.

What Happens Without a License

If no license key is configured, or if the provided key is invalid or expired:

  • Both components start normally and process all content
  • A warning is logged once at startup: WARNING: No valid license key configured. See https://modpagespeed.com/pricing/
  • The web console shows an unlicensed status indicator
  • All optimizations run without restriction

The BSL license terms still apply regardless of whether a token is present.

Trial and Evaluation

ModPageSpeed 2.0 offers a 14-day free trial. During the trial period:

  • You receive a license token with a 14-day expiry
  • All features are fully available
  • Credit card required

After the trial expires, the token verification fails with an expired status. The software continues to operate (warn-only enforcement), but your license status changes to expired in the web console and logs.

Purchase a subscription at modpagespeed.com/pricing/ to receive a production license token.

Verification

Confirm your license is active by checking the worker logs at startup:

# systemd
sudo journalctl -u pagespeed-worker | grep -i license

# Docker
docker compose logs worker | grep -i license

A valid license produces:

INFO: License valid: plan=pro, customer=you@example.com, expires=2027-01-15

An invalid or missing license produces:

WARNING: No valid license key configured. See https://modpagespeed.com/pricing/

Troubleshooting

”Invalid signature”

The token has been corrupted or truncated. Common causes:

  • Copy-paste errors (missing characters at the beginning or end)
  • Line breaks inserted into the token string
  • Wrong token (e.g., a token from a different product)

Re-copy the full token from your purchase confirmation email or the web console account page. The token is a single line with no spaces or line breaks.

”Token expired”

The exp field in the token payload is in the past. This happens when:

  • A trial period has ended
  • A subscription has lapsed

Renew your subscription to receive a new token.

”Token too short”

The base64url-decoded token is shorter than 64 bytes (the minimum Ed25519 signature size). This usually means the token was truncated during copy-paste.

License key not picked up

If the worker or nginx does not seem to read the license key:

  1. Verify the environment variable is set in the correct scope (the process that runs the binary, not just your shell session)
  2. For Docker, verify the variable appears in docker compose exec worker env
  3. For Kubernetes, verify the secret exists and is mounted: kubectl get secret <name> -o yaml
  4. For systemd, add the variable to the service file’s Environment= or EnvironmentFile= directive

Next Steps