{"id":326250,"date":"2026-06-18T06:56:28","date_gmt":"2026-06-18T06:56:28","guid":{"rendered":"https:\/\/wordpress.org\/plugins\/weamp-modpagespeed\/"},"modified":"2026-06-18T06:55:44","modified_gmt":"2026-06-18T06:55:44","slug":"weamp-cache-control-for-modpagespeed","status":"publish","type":"plugin","link":"https:\/\/wordpress.org\/plugins\/weamp-cache-control-for-modpagespeed\/","author":23516281,"comment_status":"closed","ping_status":"closed","template":"","meta":{"version":"0.1.0","stable_tag":"0.1.0","tested":"7.0","requires":"6.0","requires_php":"8.1","requires_plugins":null,"header_name":"WeAmp Cache Control for ModPageSpeed","header_author":"We-Amp B.V.","header_description":"Control panel for ModPageSpeed full-page caching: Cache-Control headers for anonymous pages, purge-on-publish, per-post-type TTLs. Requires ModPageSpeed on your server.","assets_banners_color":"0b0c0e","last_updated":"2026-06-18 06:55:44","external_support_url":"","external_repository_url":"","donate_link":"","header_plugin_uri":"https:\/\/modpagespeed.com\/wordpress\/","header_author_uri":"https:\/\/www.we-amp.com\/","rating":0,"author_block_rating":0,"active_installs":0,"downloads":35,"num_ratings":0,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","faq","changelog"],"tags":{"0.1.0":{"tag":"0.1.0","author":"oschaaf","date":"2026-06-18 06:55:44"}},"upgrade_notice":{"0.1.0":"<p>Initial release.<\/p>"},"ratings":[],"assets_icons":{"icon-128x128.png":{"filename":"icon-128x128.png","revision":3576683,"resolution":"128x128","location":"assets","locale":"","width":128,"height":128},"icon-256x256.png":{"filename":"icon-256x256.png","revision":3576683,"resolution":"256x256","location":"assets","locale":"","width":256,"height":256},"icon.svg":{"filename":"icon.svg","revision":3576683,"resolution":false,"location":"assets","locale":false}},"assets_banners":{"banner-1544x500.png":{"filename":"banner-1544x500.png","revision":3576683,"resolution":"1544x500","location":"assets","locale":"","width":1544,"height":500},"banner-772x250.png":{"filename":"banner-772x250.png","revision":3576683,"resolution":"772x250","location":"assets","locale":"","width":772,"height":250}},"assets_blueprints":{},"all_blocks":[],"tagged_versions":["0.1.0"],"block_files":[],"assets_screenshots":{"screenshot-1.png":{"filename":"screenshot-1.png","revision":3576683,"resolution":"1","location":"assets","locale":"","width":1280,"height":800},"screenshot-2.png":{"filename":"screenshot-2.png","revision":3576683,"resolution":"2","location":"assets","locale":"","width":1280,"height":800},"screenshot-3.png":{"filename":"screenshot-3.png","revision":3576683,"resolution":"3","location":"assets","locale":"","width":1280,"height":800},"screenshot-4.png":{"filename":"screenshot-4.png","revision":3576683,"resolution":"4","location":"assets","locale":"","width":1280,"height":800},"screenshot-5.png":{"filename":"screenshot-5.png","revision":3576683,"resolution":"5","location":"assets","locale":"","width":1280,"height":800}},"screenshots":{"1":"Settings page: live server status, deployment prerequisites, and cache controls.","2":"Setup wizard: six guided steps from server detection to a verified purge.","3":"Automatic server detection and connection test against the admin API.","4":"The wizard hands you the exact nginx cookie-bypass snippet your deployment needs.","5":"Final wizard check: a live test purge proves the invalidation path end to end."}},"plugin_section":[],"plugin_tags":[146,2437,187,3853,247],"plugin_category":[52,54],"plugin_contributors":[267664],"plugin_business_model":[],"class_list":["post-326250","plugin","type-plugin","status-publish","hentry","plugin_tags-cache","plugin_tags-nginx","plugin_tags-optimization","plugin_tags-page-cache","plugin_tags-performance","plugin_category-performance","plugin_category-security-and-spam-protection","plugin_contributors-oschaaf","plugin_committers-oschaaf"],"banners":{"banner":"https:\/\/ps.w.org\/weamp-cache-control-for-modpagespeed\/assets\/banner-772x250.png?rev=3576683","banner_2x":"https:\/\/ps.w.org\/weamp-cache-control-for-modpagespeed\/assets\/banner-1544x500.png?rev=3576683","banner_rtl":false,"banner_2x_rtl":false},"icons":{"svg":"https:\/\/ps.w.org\/weamp-cache-control-for-modpagespeed\/assets\/icon.svg?rev=3576683","icon":"https:\/\/ps.w.org\/weamp-cache-control-for-modpagespeed\/assets\/icon.svg?rev=3576683","icon_2x":false,"generated":false},"screenshots":[{"src":"https:\/\/ps.w.org\/weamp-cache-control-for-modpagespeed\/assets\/screenshot-1.png?rev=3576683","caption":"Settings page: live server status, deployment prerequisites, and cache controls."},{"src":"https:\/\/ps.w.org\/weamp-cache-control-for-modpagespeed\/assets\/screenshot-2.png?rev=3576683","caption":"Setup wizard: six guided steps from server detection to a verified purge."},{"src":"https:\/\/ps.w.org\/weamp-cache-control-for-modpagespeed\/assets\/screenshot-3.png?rev=3576683","caption":"Automatic server detection and connection test against the admin API."},{"src":"https:\/\/ps.w.org\/weamp-cache-control-for-modpagespeed\/assets\/screenshot-4.png?rev=3576683","caption":"The wizard hands you the exact nginx cookie-bypass snippet your deployment needs."},{"src":"https:\/\/ps.w.org\/weamp-cache-control-for-modpagespeed\/assets\/screenshot-5.png?rev=3576683","caption":"Final wizard check: a live test purge proves the invalidation path end to end."}],"raw_content":"<!--section=description-->\n<p>This plugin is the control panel for ModPageSpeed \u2014 a web server optimization module for nginx and Apache. ModPageSpeed must be installed and running on your server for this plugin to function. It is not a standalone caching plugin.<\/p>\n\n<p>The plugin does three things:<\/p>\n\n<ol>\n<li><strong>Enables full-page caching<\/strong> \u2014 adds <code>Cache-Control: public, max-age=N<\/code> to anonymous page responses (WordPress does not send this by default), with explicit bypasses for logged-in users, WooCommerce cart\/checkout\/account pages, search, feeds, and 404s.<\/li>\n<li><strong>Keeps the cache fresh<\/strong> \u2014 calls the ModPageSpeed purge API when you publish, update, or delete content, when comments change, when stock levels change, and when terms or theme settings change.<\/li>\n<li><strong>Gives you control in WP Admin and WP-CLI<\/strong> \u2014 per-post-type TTLs, cookie bypass list, excluded URL patterns, a first-run setup wizard, and <code>wp pagespeed flush|status|test-connection<\/code> commands.<\/li>\n<\/ol>\n\n<p>Works with both ModPageSpeed product lines (auto-detected), with one important difference:<\/p>\n\n<ul>\n<li><strong>ModPageSpeed 2.0<\/strong> caches full HTML pages itself \u2014 the plugin's headers and purge calls drive the module's page cache directly.<\/li>\n<li><strong>mod_pagespeed \/ ngx_pagespeed 1.1<\/strong> does not cache HTML (it is a streaming rewriter; its in-place optimization caches only images, CSS, and JS). Full-page caching on 1.1 requires an external cache layer in front (nginx <code>proxy_cache<\/code>, Varnish, or a CDN) plus <code>ModifyCachingHeaders off<\/code> or <code>DownstreamCachePurgeLocationPrefix<\/code> \u2014 with 1.1's default <code>ModifyCachingHeaders on<\/code>, the module replaces this plugin's Cache-Control header on rewritten HTML. On 1.1, the plugin's purge calls evict optimized sub-resources and metadata, not HTML pages.<\/li>\n<\/ul>\n\n<h4>Server requirements<\/h4>\n\n<ul>\n<li>ModPageSpeed 1.1 (v1.15.0+r3 or later) or ModPageSpeed 2.0 (v2.0.0 or later) installed on your web server.<\/li>\n<li>For 2.0: the worker admin API enabled (<code>--api-port<\/code>).<\/li>\n<li>For full logged-in-user correctness an nginx cookie-bypass map block is required \u2014 the setup wizard provides a copy-paste snippet and verifies it.<\/li>\n<\/ul>\n\n<h4>WP-CLI<\/h4>\n\n<ul>\n<li><code>wp pagespeed flush [--url=&lt;url&gt;]<\/code> \u2014 purge the home page (and posts page), or one specific URL on this site.<\/li>\n<li><code>wp pagespeed status<\/code> \u2014 detected product, version, license tier, purge prerequisites, and last-purge status.<\/li>\n<li><code>wp pagespeed test-connection<\/code> \u2014 verify the admin API is reachable and correctly configured (read-only, never purges).<\/li>\n<\/ul>\n\n<h4>License<\/h4>\n\n<p>This plugin is free software, licensed under the GNU General Public License v2.0 or later. The full GPL-2.0 license text is bundled with the plugin in the LICENSE file.<\/p>\n\n<h3>Third Party Services<\/h3>\n\n<p>This plugin makes HTTP requests to the operator-configured ModPageSpeed admin API URL. Data sent includes page URLs (for cache purging) and an API key (for authentication). No data is sent to We-Amp or any third party.<\/p>\n\n<!--section=installation-->\n<ol>\n<li>Install ModPageSpeed on your server (see https:\/\/modpagespeed.com\/).<\/li>\n<li>Install and activate this plugin.<\/li>\n<li>Follow the setup wizard under Settings &gt; ModPageSpeed: detect your server, enter the admin API URL, test the connection, apply the nginx.conf snippet, enable caching, and run a test purge.<\/li>\n<\/ol>\n\n<!--section=faq-->\n<dl>\n<dt id=\"does%20this%20plugin%20cache%20pages%20itself%3F\"><h3>Does this plugin cache pages itself?<\/h3><\/dt>\n<dd><p>No. Caching happens server-side: in the ModPageSpeed 2.0 module itself, or \u2014 on 1.1 \u2014 in your front cache (proxy_cache, Varnish, or CDN; the 1.1 module does not cache HTML, see the Description). The plugin only sets cache headers and sends purge requests \u2014 the same architecture as other server-layer cache plugins.<\/p><\/dd>\n<dt id=\"i%20run%20mod_pagespeed%20%2F%20ngx_pagespeed%201.1%20%E2%80%94%20do%20i%20get%20full-page%20caching%3F\"><h3>I run mod_pagespeed \/ ngx_pagespeed 1.1 \u2014 do I get full-page caching?<\/h3><\/dt>\n<dd><p>Not from the module alone. 1.1 never caches HTML; put an external cache (nginx <code>proxy_cache<\/code>, Varnish, or a CDN) in front of it and set <code>ModifyCachingHeaders off<\/code> (or use <code>DownstreamCachePurgeLocationPrefix<\/code>) so this plugin's Cache-Control headers reach that cache. The plugin's purge calls on 1.1 evict optimized sub-resources and metadata.<\/p><\/dd>\n<dt id=\"does%20it%20work%20without%20modpagespeed%20installed%3F\"><h3>Does it work without ModPageSpeed installed?<\/h3><\/dt>\n<dd><p>No. The setup wizard will guide you to the server module installation docs if no server is detected.<\/p><\/dd>\n\n<\/dl>\n\n<!--section=changelog-->\n<h4>0.1.0<\/h4>\n\n<ul>\n<li>Initial release: Cache-Control headers for anonymous pages, purge on publish\/update\/delete\/comment\/stock changes, ModPageSpeed 1.1 and 2.0 support with auto-detection, setup wizard, WP-CLI commands.<\/li>\n<\/ul>","raw_excerpt":"Full-page caching control panel for the ModPageSpeed server module: cache headers, purge-on-publish, per-post-type TTLs.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/326250","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=326250"}],"author":[{"embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/oschaaf"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=326250"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=326250"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=326250"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=326250"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=326250"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=326250"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}