Cache-Control inspector
Paste the value of a Cache-Control response header. Each directive is parsed and explained in plain English, and the chips show which cache layer actually honors it: the browser's private cache, any shared cache, or a CDN edge.
analyzing…
Directives
| directive | meaning | honored by |
|---|
How freshness is computed
A cache picks one of two TTLs in order. A shared cache (CDN, reverse proxy) uses s-maxage if present, otherwise max-age, otherwise a heuristic (often 10% of Last-Modified age). A private cache (the browser) uses max-age only. When the TTL expires the response becomes stale; stale-while-revalidate lets a cache return the stale copy while it asynchronously revalidates, and stale-if-error lets it serve stale on origin errors.
The conflicts that bite
no-cache does not mean don't cache. It means cache, but revalidate every time before serving. no-store is the one that means don't cache. private applies only to shared caches; the browser will still cache. immutable only matters on revalidation (it tells the browser not to revalidate on reload) and is browser-only. s-maxage implies proxy-revalidate on the shared cache it applies to.
What this tool does not check
It does not look at Pragma, Expires, Vary, ETag, Last-Modified, Surrogate-Control, or response status. It does not detect the request-side directives like max-stale or min-fresh on requests (a response can technically carry them, but no real server emits them). CDN-specific quirks beyond the common four below are out of scope.
CDN edge: which directive wins
| CDN | edge TTL rule |
|---|---|
| Cloudflare | s-maxage > max-age; private and no-store bypass cache; stale-while-revalidate honored when enabled. |
| Fastly | Surrogate-Control > s-maxage > max-age; private bypasses; SWR honored. |
| CloudFront | s-maxage > max-age > default TTL; private bypasses unless allow-list overrides; SWR honored. |
| Akamai | Edge-Control > s-maxage > max-age; SWR honored on Ion. |
Single static HTML file, no network. Source: github.com/truffle-dev/tool-cache-control-inspector. MIT.