Website gets HIT only on www and not on naked



Hi there.
I use curl to check if my website is reachable on the CF, and weirdly only the www. version gets HIT and non-www gets MISS all the time.

Is there is a way to set up that both works globally?

I have no page rule related to that and believe this can be fixed from DNS or global settings.



On non-www i get this:

Cache-Control: public, max-age=31536000, no-cache


Your origin is sending the no-cache directive and we’re respecting that. The www is sending a 301 redirect. It’s the 301 which is being cached, not the content.

  • If the Cache-Control header is set to “private”, “no-store”, “no-cache”, or “max-age=0”, or if there is a cookie in the response, then Cloudflare will not cache the resource.


Thanks for the response! In my CF dashboard, i’ve set the Browser Cache Expiration to 1 month. Doesn’t this overwrite origin cache control?



The Cache Expire TTL rule will overwrite origin cache control.

You can read about it here:


This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.