Why is my website not being cached?

That seems to be the problem. Please remove the leading asterisk ‘*’ and replace it with the scheme, so your rule becomes:

https://circles.gallery/_app/*

Then clear cache and try again.

Hmm but wouldn’t this leave out https://www.circles.gallery/_app/*?

Actually yes, but please first try it, so we see it the pattern now is matching, then we can go from there on.

I was referring to this page: https://support.cloudflare.com/hc/en-us/articles/218411427-Understanding-and-configuring-Cloudflare-Page-Rules-Page-Rules-Tutorial-

It says below:

To match every page on a domain and it's subdomains, write *example.com/*. Just writing example.com won’t work.

I’ve just changed the rule to what you said. Do you know how long does it take to propagate through the system?

I know, but lately some rules did not match their expected pattern. Thats why I asked for. Should have happened immediately. You can change it back - did not work.

ATM I am clueless, don’t know all you other settings so hard to say anything precise.

I just tried adding Edge Cache TTL, Browser Cache TTL along side Cache Everything directive. If it should have been activated immediately, it did not work as well.

Hmm, are there any other related piece of setting that might affect this? I devoured all the documentation and community questions available, but my setup looks okay.

The origin server is behind render.com, not sure if they are not playing nicely somehow?

Possibly, it looks like render is using Cloudflare themselves, with their own IP addresses though

https://render.com/cdn-cgi/trace

But I have an “A record” pointing to my origin server IP. How could Render interfere with this traffic?
I’m not sure what I am saying is not very logical though.

Could you guide me to where can I send an email to Cloudflare Support for checking this out?

So my understanding is that because your host is using Cloudflare, only their settings will apply

1 Like

Wow interesting!!

However, it also says the following.

What Cloudflare currently does about it
Currently, any record pointing to a :orange: host is automatically set to :grey: and cannot be changed to :orange:. Going back to the example above, this means that because customer.host.com is set to :orange:, www.customer.com cannot be :orange: and is therefore set to :grey:. This means that certain Cloudflare services such as page rules and workers cannot currently be used in this situation.

My DNS setup indicates I am :orange:, anyways, I will ask this to Render’s support as well.

1 Like

If you use a CNAME to your onrender subdomain instead of an A record the IP, Cloudflare should send the traffic to your zone before going through Render’s.

Hmm I found a relevant discussion in Render’s community support page:

Will check using CNAME, thank you!

Hmm now I am using a CNAME to circlesgallerywebsite.onrender.com, with Cloudflare proxying enabled.
I can now see cf-cache-status: MISS header, rather than the BYPASS! I think this is a step towards the right direction?
Would using this configuration raise any other issues? Should I turn off the :orange: ?

1 Like

There shouldn’t be any issues with this configuration. There are a number of Render users currently doing this. It was the recommended setup from Cloudflare.

1 Like

Sorry the first request always is a MISS in cache, try to hardreload 2-3 more times. I ATM see HITs.

It was the recommended setup from Cloudflare.

I am very sure it was not like this a couple months ago when I setup the domain!

Thank you everyone! I am now seeing HITs starting to appear!
Will leave the docs here for others: Configuring Cloudflare DNS | Render

2 Likes

Hmm sorry I know I’ve accepted an answer, but I’m seeing MISS for most of my static assets.
Edge TTL should be 7 days, and I thought after seeing HITs appearing yesterday, I thought I would have HITs today as well.
Could it be that Render’s cache settings are being applied rather than mine?

As a matter of fact, they are all MISS for me

I’m seeing HITs for your .js assets

image

It all depends on the COLO you are reaching, and your Cloudflare Plan, caches are prioritized in order of plans respectively, i.e. Free tier assets will be purged from Cloudflare’s caches first when needed, then Pro, then Business, then Enterprise

1 Like

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