Skip to main content
ModPageSpeed 2.0: AVIF, WebP, and critical CSS — up to 69% less page weight on the live demo

ngx_pagespeed alternative

The nginx PageSpeed port lives on. The module you knew as ngx_pagespeed is now mod_pagespeed 1.15: the same native nginx module, the same pagespeed directives, built against current nginx and security-patched. Maintained by the people who maintained the original.

Production use requires a commercial license — but the software never locks you out.

Install it in two commands

# Ubuntu / Debian
curl -fsSL https://packages.modpagespeed.com/install.sh | sudo sh
apt install nginx-module-pagespeed

# AlmaLinux / RHEL
curl -fsSL https://packages.modpagespeed.com/install.sh | sudo sh
dnf install nginx-module-pagespeed

mod_pagespeed 1.15 — the maintained nginx module

1.15 loads into your nginx binary the way ngx_pagespeed did. The module is named ngx_pagespeed.so because it is the nginx port — the one you came here for. Install the signed package, add one load_module line, and keep the pagespeed directives, filter selectors, and URL-based variant fan-out you already wrote.

# nginx.conf — mod_pagespeed 1.15 native module
load_module modules/ngx_pagespeed.so;

pagespeed on;
pagespeed FileCachePath /var/cache/ngx_pagespeed;
pagespeed RewriteLevel CoreFilters;

It is the same ngx_pagespeed.so, bit-compatible with open-source mod_pagespeed: same directives, same filters. There is no separate worker, no reverse-proxy hop, and no container. What changed: the module builds against current nginx, ships current image and TLS dependencies, and takes CVE patches again.

1.15 carries the full classic filter set: combine_css, combine_javascript, image spriting, in-place resource optimization, domain mapping, DNS prefetch. It adds the built-in /pagespeed_admin/ console and per-filter control. It optimizes images to WebP alongside JPEG, PNG, and GIF.

It runs natively on Apache, nginx, and IIS (Envoy experimental). That makes it the only PageSpeed build that loads inside Apache and IIS, and the successor to IISpeed.

mod_pagespeed 1.15 docs · Package repositories (packages.modpagespeed.com) · Buy a license

Who maintains it

We-Amp B.V., based in Castricum, Netherlands. Founder Otto van der Schaaf was a maintainer of Google's mod_pagespeed and helped ship the open-source 1.13.35.2 release. We-Amp owns ngxpagespeed.com, the historical landing page for the nginx port. When upstream development moved to the Apache Software Foundation and then wound down, the nginx module did not stop. Its maintainers kept shipping it.

Why a maintained continuation matters

Google donated mod_pagespeed and ngx_pagespeed to the Apache Software Foundation in 2017. The Apache Incubator podling retired in 2023, and the repository at apache/incubator-pagespeed-ngx was marked read-only in 2025. The archived sources still document a good design. They no longer build cleanly against current nginx without patching — we wrote up why ngx_pagespeed won't build on modern nginx (and the prebuilt fix), and the ngx_pagespeed alternative on ngxpagespeed.com walks through the prebuilt nginx module in more detail. Their image and TLS dependencies carry known CVEs that nobody is patching. A read-only repository is the reason to move to a maintained continuation, not the reason to leave nginx-native optimization behind. That is the gap 1.15 closes: same module, still building, still patched.

If you want the new architecture: ModPageSpeed 2.0

ModPageSpeed 2.0 is the ground-up C++23 rewrite. Instead of loading into nginx, it runs as a Docker reverse proxy in front of nginx (or any HTTP origin), which keeps optimization work off the request path. The proxy checks the cache and serves the variant via zero-copy mmap on a hit. On a miss it serves the original and notifies a separate worker. The worker decodes once and generates up to 37 variants per asset: WebP, AVIF, viewport sizes, pixel densities, save-data, plus SVG for eligible images. It writes them to the variant-aware cache, which the next request reads from a hit.

The optimization core underneath is the same PSOL core that ngx_pagespeed used. The architecture around it is new. AVIF ships only here.

# docker-compose.yml — ModPageSpeed 2.0 reverse proxy in front of nginx
services:
  modpagespeed:
    image: weamp/modpagespeed:2
    ports:
      - "80:8080"
    environment:
      PAGESPEED_ORIGIN: "http://nginx:80"
    volumes:
      - cache:/var/cache/modpagespeed
volumes:
  cache:

On ASP.NET Core, skip the proxy and run 2.0 as native middleware:

# ModPageSpeed 2.0 - ASP.NET Core middleware
dotnet add package WeAmp.PageSpeed.AspNetCore

.NET quickstart · Download & run ModPageSpeed 2.0

1.15 or 2.0 for nginx

Two first-class products. They share one optimization core (PSOL), one cache (Cyclone), and one per-site license ladder: a Business license is $948/year or $99/month per site, with unlimited servers per site, and covers either product. Pick by deployment fit, not by which is newer.

What you want mod_pagespeed 1.15 (nginx module) ModPageSpeed 2.0 (worker + proxy)
Deployment Native in-process nginx module (load_module) Docker reverse proxy in front of nginx, or ASP.NET Core middleware
Configuration Your existing pagespeed directives, unchanged Smaller directive surface; worker model differs from inline rewriting
Image formats WebP, JPEG, PNG, GIF AVIF + WebP, plus SVG for eligible images
Cache serving File cache on the request path Variant-aware cache, zero-copy mmap on hits
Admin / stats Built-in /pagespeed_admin/ console Worker dashboard and stats
Other servers Native on Apache and IIS (Envoy experimental) Fronts any HTTP origin; native ASP.NET Core middleware

Migration

Coming from ngx_pagespeed 1.13.35.2, 1.15 is a package swap. Install the signed nginx-module-pagespeed from packages.modpagespeed.com and keep your directives unchanged.

Moving to the 2.0 worker model is a re-architecture. The directive surface is intentionally smaller and the rewriting model differs from inline rewriting. The migration notes cover what stays, what changes, and how the worker model works.

Frequently asked questions

Is the nginx port still maintained?

Yes. mod_pagespeed 1.15 is the maintained continuation of the nginx port. It ships a native nginx module — the same ngx_pagespeed.so, the same pagespeed directives — built against current nginx, with current image and TLS dependencies and applied CVE patches. We-Amp helped ship the open-source 1.13.35.2 release and kept the module going.

Can I keep my existing pagespeed directives?

Yes. mod_pagespeed 1.15 is bit-compatible with open-source mod_pagespeed. The pagespeed directives and filter selectors you already wrote keep working. Install the signed package, add the load_module line, keep your config.

What happened to the old ngx_pagespeed repository?

Google donated mod_pagespeed and ngx_pagespeed to the Apache Software Foundation in 2017. The Apache Incubator podling retired in 2023, and apache/incubator-pagespeed-ngx was marked read-only in 2025. The archived sources no longer build cleanly against current nginx without patching. The module itself did not stop. Its maintainers kept shipping it as mod_pagespeed 1.15.

What is ModPageSpeed 2.0, and when would I want it instead?

ModPageSpeed 2.0 is the newer out-of-process architecture: a worker behind an nginx reverse proxy (Docker), or native ASP.NET Core middleware. It keeps optimization off the request path. It serves cache hits via zero-copy mmap. It adds AVIF and a variant-aware cache. Choose it for a new container-native deployment, or when you need AVIF. Choose 1.15 for a native in-process nginx module that drops in where ngx_pagespeed sat.

Which products generate AVIF?

ModPageSpeed 2.0 generates AVIF variants when the client signals support. mod_pagespeed 1.15 optimizes images to WebP alongside JPEG, PNG, and GIF. If AVIF is a requirement today, that points to 2.0.

Who maintains this?

We-Amp B.V., based in Castricum, Netherlands. Founder Otto van der Schaaf was a maintainer of Google's mod_pagespeed and helped ship the open-source 1.13.35.2 release. We-Amp owns ngxpagespeed.com, the historical landing page for the nginx port.

Try one

  • mod_pagespeed 1.15 (nginx) — install the signed nginx-module-pagespeed package from packages.modpagespeed.com: curl -fsSL https://packages.modpagespeed.com/install.sh | sudo sh, then apt install nginx-module-pagespeed (Ubuntu) or dnf install nginx-module-pagespeed (AlmaLinux/RHEL). · docs
  • ModPageSpeed 2.0dotnet add package WeAmp.PageSpeed.AspNetCore · .NET quickstart · Download & run · Buy a license

Related

ngx_pagespeed, nginx, and other product names are trademarks of their respective owners. Comparisons reflect publicly available information as of 2026 and are provided for evaluation; We-Amp B.V. is not affiliated with or endorsed by Google or the Apache Software Foundation.