Skip to content
StaticScope
Overview
Get StaticScope

Caching plugins when the site is already static

Page caching is redundant on a static host, but minify, lazy load and CDN settings still matter. Here is what to keep and what to switch off.

Plugins Updated 21 November 2026 4 min read

A caching plugin exists to stop WordPress doing the same work twice. It stores the rendered page and serves it without booting PHP. On a static host, the page already is the stored version. The file is the cache, and there is no WordPress to skip.

That makes the page-cache half of WP Rocket, LiteSpeed Cache, W3TC, WP Super Cache and the rest redundant on the published site. It does not make the whole plugin useless. Some of its other features still shape the files you publish, and some of them can break the build without warning.

What still applies

FeatureStill useful?Why
Full-page cacheNoThe HTML file is the cache. Keeping a second one only adds a layer that can serve the crawler an old page.
Object cache and database cacheNoNo PHP, no database and no queries on the published site.
Minify and combine CSS or JavaScriptOptionalUseful once, at build time. Generated at request time, it can produce a different page for the crawler than for a visitor.
Critical CSS or used CSSCarefulOften generated on demand. If it is not ready when the page is crawled, the build ships without it or points at a file that is not there.
Lazy loadSometimesWorks when the URL stays in the markup. Fails when a script builds the URL after load.
Image conversion to WebP or AVIFYesCheck the converted files are copied and referenced. The original may be all the crawler saw.
CDN rewritingYes, with careAssets on another host are not copied into the build. That can be intended, or a dependency on WordPress.
Preload and prefetchYesBrowser-side hints. They travel with the page.

The stale-output problem

The worst outcome is a build that captures yesterday’s page. It happens more often than people expect. You edit a post, the cache still holds the old version for a few minutes, the build runs and the static site gets the old content. The build report is green because the files are all present and none of them point at WordPress. They are out of date.

A cache can also serve different HTML to the crawler than to a browser. Some optimisers defer CSS or JavaScript by rewriting the markup with JavaScript, and the rewritten version depends on a cookie or a warm cache. The crawler is anonymous, so it may get the cold version.

The fix is to purge before every build, or to exclude the crawler’s user agent. StaticScope identifies itself as StaticScope.com, and staticscope_curl_user_agent changes it. Add that agent to the cache plugin’s exclusion list so it always gets a fresh render.

Double caching and the host

Once the site is published, the caches that matter are in front of it: the host’s CDN, Cloudflare, a corporate proxy, or a service worker in the browser. A static file with a long cache lifetime will keep serving the old page long after a deploy. That is the cache to purge, not the WordPress one.

Serve HTML with a short lifetime and assets with a long one. The S3 add-on already sets pages to public, max-age=0, must-revalidate and other files to one hour, and both values have filters. On Netlify, Cloudflare Pages and GitHub Pages, the deploy normally replaces the files, but a proxy in front can still hold the old HTML. StaticScope’s completion webhook exists for this: send a request to your cache’s purge endpoint after each publish.

If you rename assets on every build, a long cache is safe for them. If a stylesheet keeps the same name, a long cache will pair new HTML with old CSS. That is the classic broken layout after a deploy, and it is a caching decision, not a builder bug.

What to keep, what to switch off

  • Keep image optimisation if it produces files the pages reference. Check a converted image is in the build and the page asks for it.
  • Keep a CDN only if you understand that its assets live outside the build. If the CDN is tied to the WordPress site, it becomes a leak after publishing.
  • Keep preload and prefetch hints. They cost nothing on a static host.
  • Switch off full-page caching during the build, or purge it first. A stale page is worse than a slow one.
  • Switch off anything that generates CSS or JavaScript on first request, unless you have checked the built output. Critical CSS, used CSS and some combine features are the usual suspects.
  • Prefer native loading="lazy" over a JavaScript lazy loader. It needs no script and the URL is always in the markup.
  • Do not install a caching plugin on a static host. There is no PHP to run it, and no benefit if there were.

Minify once, not per request. If a minifier runs at request time, two requests can produce two different files. The crawler saves one of them. Build-time minification or host-level minification gives you the same output every time.

Next