I Documented My Static Site's Cache Headers. curl -I Says Otherwise. A developer documented that their Firebase Hosting cache rules for a static Next.js site never worked as published: the HTML rule's glob matched request paths ending in .html, but cleanUrls and trailingSlash meant no real request ever used that form, so pages, llms.txt and sitemap.xml were all served with Firebase's default max-age=3600 instead of max-age=0, must-revalidate. A second rule intended for content-hashed bundles instead matched by file extension, leaving the headshot and site icon cached as immutable for a year. The developer traced both mismatches to verifying the config file rather than the live response headers via curl -I. A few weeks ago I wrote up how my personal site is built for search engines and AI crawlers: a static Next.js export, one typed registry of posts that drives everything, Article and FAQ structured data, an llms.txt , IndexNow on deploy, and a caching policy on Firebase Hosting. I described that caching policy with some confidence. HTML gets max-age=0, must-revalidate , hashed assets get cached for a year. Then I ran curl -I against the live site, which is something I should have done before writing the sentence. for u in / /blog/developer-blog-seo-ai-search-nextjs-static/ /llms.txt /sitemap.xml; do curl -sI "https://nabeelbaghoor.com$u" | grep -i cache-control done Every one of them came back cache-control: max-age=3600 . Not the header I wrote. Not the header in my config. Firebase's default. This post is about why, and about the second mismatch I found while I was in there, because both come from the same habit: I verified the config file and never verified the output. Here is the relevant part of firebase.json , unchanged since the site's first commit in July: { "hosting": { "public": "out", "cleanUrls": true, "trailingSlash": true, "headers": { "source": " / .@ js|css|svg|jpg|jpeg|png|woff2 ", "headers": { "key": "Cache-Control", "value": "public, max-age=31536000, immutable" } }, { "source": " / .@ html ", "headers": { "key": "Cache-Control", "value": "public, max-age=0, must-revalidate" } } } } Read it as a file list and it is fine. The export writes out/blog/some-post/index.html , and index.html ends in .html , so the second rule covers it. But the source glob is matched against the request path, not against the file that ends up being served. With cleanUrls and trailingSlash on, nobody ever requests a path ending in .html . Readers and crawlers ask for /blog/some-post/ . If you do ask for the .html file directly, Firebase answers with a 301 to the clean URL: curl -sI https://nabeelbaghoor.com/blog/developer-blog-seo-ai-search-nextjs-static/index.html HTTP/2 301 location: /blog/developer-blog-seo-ai-search-nextjs-static/ So the HTML rule has never matched a single real request. Every page, plus llms.txt , sitemap.xml and the small .txt payloads Next.js uses for client-side navigation, has been served with Firebase's default one hour. For a blog, one hour of staleness after a deploy is honestly not a disaster. What bothers me is that I published the wrong number as a recommendation, with my own site as the example. The first rule has the opposite problem. It does match, and it matches more than I meant. The reasoning behind immutable for a year is that the files have content hashes in their names, so a new version gets a new URL. That is true for everything under / next/static/ . It is not true for files I put in public/ myself: curl -sI https://nabeelbaghoor.com/assets/nabeel.jpeg | grep -i cache-control cache-control: public, max-age=31536000, immutable curl -sI https://nabeelbaghoor.com/icon.svg | grep -i cache-control cache-control: public, max-age=31536000, immutable That is my headshot and the site icon. If I replace either one and keep the filename, a returning visitor's browser is allowed to keep showing the old one for a year without asking. The glob was written for hashed bundles and I pointed it at file extensions instead of at the folder that actually holds hashed files. While checking this I also noticed the export still ships the starter next.svg , vercel.svg , file.svg , globe.svg and window.svg from create-next-app , also cached as immutable. Harmless, but it tells you how closely I had looked at out/ . The same article says the framework, the host and the canonical tags must agree on one URL form, or you get redirect chains. My site uses trailing slashes. So I checked what the canonical tag says: curl -s https://nabeelbaghoor.com/blog/developer-blog-seo-ai-search-nextjs-static/ \ | grep -o '