CSS Caching Test
The CSS Caching Test inspects the Cache-Control headers on every .css file referenced by a URL and reports whether each is being cached aggressively, briefly or not at all.
- Results in seconds
- Pass / fail + fix guidance
- No account required
The CSS Caching Test inspects the Cache-Control headers on every .css file referenced by a URL and reports whether each is being cached aggressively, briefly or not at all. Versioned stylesheets (with a hash in the filename) can be cached for a year with the immutable directive — making repeat visits effectively free. Unhashed stylesheets need shorter lifetimes to allow updates.
What This Tool Checks
- Cache-Control header per .css file
- max-age and immutable directives
- Versioned stylesheet detection
- Inline critical CSS vs external CSS
- CDN cache hit ratio for CSS
- ETag headers for revalidation
Why It Matters for SEO
CSS bundles are usually small but on the critical render path — a slow CSS request blocks first paint. Caching them aggressively turns repeat visits into immediate paints. Most modern build pipelines output content-hashed CSS, making 1 year + immutable trivially safe. The only risk is third-party stylesheets (Google Fonts, framework defaults) that you do not control.
How to Fix It
For hashed CSS bundles: Cache-Control: public, max-age=31536000, immutable. For unhashed CSS: shorter max-age with revalidation. Self-host fonts and framework CSS where possible to control cache lifetime. Inline only the truly critical above-the-fold CSS; cache the rest aggressively.
How It Works
We walk every <link rel="stylesheet"> on the page, request each with HEAD, capture cache headers, and detect content-hashing in URLs. Recommendations are tailored per asset based on whether the URL is safely versioned.
Common Mistakes to Avoid
- Hashed CSS cached for only an hour
- Missing immutable on hashed CSS URLs
- External Google Fonts CSS adding cross-origin requests on every visit
- Cache-Control: no-cache on critical CSS
- Inlining all CSS instead of caching the external bundle
Quick Checklist
- Hashed CSS cached 1 year with immutable
- Critical above-the-fold CSS inlined
- External fonts self-hosted where possible
- No Cache-Control: no-cache on production CSS
- CDN responds HIT on repeat CSS requests
Put your whole site on autopilot — SEO and AI search
PositionMySite monitors every signal on this page across your entire website 24/7 — plus keyword rankings, competitor moves and AI-search readiness (llms.txt, schema, ChatGPT & Gemini visibility). When something breaks, you know before Google does.
Every feature unlocked · No commitment · Cancel anytimeFrequently Asked Questions
Hashed bundles can be cached for 1 year with immutable. Unhashed stylesheets should cache for shorter periods (hours to days) so style updates propagate to users quickly.
Inline only the critical above-the-fold CSS to unblock first paint. Cache the rest of the stylesheet externally so repeat visits skip the download.
Because it is a separate cross-origin request that cannot be inlined or cached at your domain. Self-host fonts via the @font-face CSS rule for full cache control and faster paint.
Yes. Cached CSS means no render-blocking download on repeat visits, dramatically improving FCP and LCP for returning users. CrUX field data reflects this in your Core Web Vitals scores.
Yes — Cookies on the page do not affect CSS caching unless the CSS response itself sets cookies. Most CDNs cache CSS independently of page cookies.