Cloudflare purges propagate globally in seconds, so when stale content survives a purge, the purge is rarely the broken part. Either the purge did not match what is actually in the cache (single-file purges are exact-match against the cache key), or the stale copy never lived in Cloudflare’s cache at all — it is in the visitor’s browser or in a cache behind your origin. The age header tells you which in one request.
What’s happening
Three cache layers can hold a stale copy: the browser (controlled by Cache-Control sent to visitors), Cloudflare’s edge, and origin-side caches (page-cache plugins, Varnish, LiteSpeed). A Cloudflare purge touches exactly one of the three. And Cloudflare only holds what it was told to cache — static extensions by default, HTML only if a Cache Rule or APO says so — so a purge cannot fix staleness in content the edge never stored.
Each purge type has different reach. Purge Everything drops the whole zone from every data centre — thorough, but it exposes your origin to a full refill. Purge by URL removes only entries whose cache key matches the URL exactly: scheme, host, and query string included, and if a Cache Rule customized the cache key, a plain URL purge can miss the stored variants. Purge by hostname, tag, or prefix are Enterprise features. Purges also clear both layers of Tiered Cache, and remove matching objects from Cache Reserve if you use it. What no purge ever does: reach into a browser that was told to keep the file for a week, or clear a cache running behind your origin.
What to check first
- The
ageheader after the purge. Ifagereset to a small number, the purge worked and the “stale” content is coming from somewhere else. - Whether the purged URL matches the cached one.
httpsvshttp,wwwvs apex, trailing slash, and query strings all change the cache key. - Whether the content was ever edge-cached.
cf-cache-status: DYNAMICmeans there was nothing to purge. - Who reports the staleness. One user on one device points at browser cache; everyone everywhere points at edge or origin.
How to verify
Purge, then immediately read the headers twice:
curl -sI https://example.com/assets/app.css | grep -iE '^(cf-cache-status|age|cache-control|last-modified)'
curl -sI https://example.com/assets/app.css | grep -iE '^(cf-cache-status|age|cache-control|last-modified)'
After a successful purge the first request reads MISS (or EXPIRED) with the new content, the second reads HIT with age near zero. If curl shows fresh content while a browser shows stale, the browser cache is the culprit — check the cache-control max-age you are sending visitors. Next, compare against a cache-busted request, which skips every HTTP cache key:
curl -s "https://example.com/assets/app.css?v=$(date +%s)" | head -5
If even the cache-busted copy is old, the stale content is generated at the origin — an origin cache holds it, and Cloudflare is only relaying. Confirm by asking the origin directly:
curl -sI https://example.com/assets/app.css --resolve example.com:443:203.0.113.10 | grep -iE '^(age|cache-control|x-cache|x-litespeed-cache)'
The fix
- Stale only in browsers: wait or rename. No Cloudflare action clears visitor browsers. Either wait out the
max-ageyou shipped, or change the URL (a versioned filename or query string). For the future, shorten Browser TTL on mutable files. - Single-file purge missing: purge the exact key. Purge each real variant —
https://www.example.com/page/andhttps://example.com/page/are different keys, and so is every query-string variant when the query string is in the cache key. When variants multiply, Purge Everything is the honest tool on non-Enterprise plans. - Custom cache keys: purge accordingly. If a Cache Rule ignores the query string or adds headers to the key, purge the URL form that matches the key Cloudflare stored, not the URL a visitor typed.
- Stale at the origin: purge the origin cache. Clear the page-cache plugin, LiteSpeed, or Varnish first, then purge Cloudflare so the edge refills with the fresh copy — the order matters.
- Cache Reserve users: expect it to be included, and watch cost. Purge by URL removes the object from Cache Reserve too; frequent Purge Everything on a zone with Cache Reserve re-triggers the storage writes you pay for. Details in Tiered Cache and Cache Reserve.
When this fix is wrong
If purges “stop working” every day at the same time, you do not have a purge problem — you have an upstream process re-publishing old content (a scheduled export, a CI job deploying an old artifact). If only logged-in users see stale data, look at application-level caches (object cache, transients), which no HTTP purge touches. And if you are purging to hide a deploy problem several times a week, the fix is a deploy-time purge pipeline, not more clicking.
Common mistakes
- Purging
http://when the cache holdshttps://, or the apex when visitors hitwww. - Expecting purge to clear browsers — it never does.
- Purging Cloudflare while a LiteSpeed or Varnish layer behind it still serves the old copy to the edge on refill.
- Treating
cf-cache-status: DYNAMICcontent as purgeable — there is nothing stored. - Running Purge Everything on a high-traffic zone at peak and blaming Cloudflare for the origin load spike that follows.
Prevention
Decide the purge pattern per content class before you need it — the trade-offs between Purge Everything, purge by URL, and the Enterprise selectors are laid out in Cloudflare cache purge strategies. Keep Browser TTL short on anything you may need to retract, since browsers are the one cache you cannot reach. Automate purges through the purge API in your deploy pipeline instead of relying on dashboard clicks after the fact.
A purge that “did not work” is nearly always a purge aimed at the wrong layer. Cache layers that fight each other cost real revenue — Stack Harbor tunes the whole stack, edge to origin, under Managed Cloud Ops; book an infrastructure review.