Static assets have long-lived cache headers configured
Why it matters
Browser cache headers control whether a returning visitor re-downloads assets on every page load or serves them from the local disk cache in milliseconds. Without Cache-Control: public, max-age=31536000, immutable on hashed static assets, every visit — including from users who visited yesterday — initiates fresh network requests for all JavaScript bundles, CSS, and images. ISO-25010 resource-utilisation covers this: downloading the same unchanged 200KB bundle on every repeat visit is pure waste. Modern frameworks (Next.js, Vite, webpack) include content hashes in filenames, making year-long browser caches safe — changing any file produces a new filename, so stale cache never serves outdated content.
Severity rationale
Medium because absent long-lived cache headers cause repeat visitors to re-download all assets unnecessarily, increasing page load times and bandwidth costs, but the impact is limited to returning users rather than first-visit acquisition.
Remediation
Configure long-lived immutable cache headers for hashed static assets and short-lived revalidation headers for HTML. On Vercel with Next.js, static chunks already receive max-age=31536000, immutable — verify this is not overridden.
// vercel.json — explicit rules for custom asset types
{
"headers": [
{
"source": "/(.*)\\.(js|css|woff2|webp|avif)$",
"headers": [
{ "key": "Cache-Control", "value": "public, max-age=31536000, immutable" }
]
},
{
"source": "/(.*)\\.html$",
"headers": [
{ "key": "Cache-Control", "value": "public, max-age=0, must-revalidate" }
]
}
]
}
For custom Express servers, add serve-static with maxAge: '1y' for the public/ directory, or set headers explicitly in middleware for the /_next/static/ path.
DetectionPro
The detection method for this pattern is part of AuditBuffet Pro.
The full method (what to look for, pass and fail conditions, and how results get reported) ships inside the Page Speed Audit. The pattern definition, severity rationale, and remediation remain openly licensed under CC-BY-4.0.
External references
- iso-25010:2011 · performance-efficiency.resource-utilization — Long-lived cache headers — eliminates redundant asset downloads
Taxons
History
- 2026-04-18·v1.0.0·Initial import from marketing-page-speed·automated