And I took the steps described in those to disable any Cloudflare features that could be causing the Etag header to not be included.
After failing to solve the issue that way, I began trying to solve this on the Cloudflare Pages URL (listening-spaces.pages.dev) in order to bypass any incorrect configuration that I might have on my custom domain, but I’m still unable to get the Etag header to make it to my browser.
Thanks for the reply! As far as I can tell, that thread is not helpful in this case.
I’m specifically trying to get the Etag header to show up on a Cloudflare Pages site, where I have minimal control over the server behavior. (Eventually I’d like to get the Etag header to make it all the way through my custom domain, proxied by Cloudflare, but for now I’m trying to narrow down the problem and focus just on the page as its being served on the *.pages.dev domain.)
This docs page claims that “Pages always sends Etag headers for 200 OK responses”: Serving Pages | Cloudflare Pages docs
It makes no mention of things that might be causing the header to be removed.
The only potentially relevant things in my control that I could think of on a Cloudflare Pages site are the manual headers control via the _headers file and Web Analytics, which injects a script into the page. I’ve tried with and without Web Analytics, and I’ve tried with and without a _headers file.
I’ve got the same issue here on a pure, minimal Cloudflare Pages project. I noticed that CSS, mages, etc. get an ETag header (some strict, some weak), while HTML does not. I don’t have a _headers file or any other caching-related configuration.