Exclude WordPress backoffice from Cloudflare

Hi guys,
We are working on the optimization of radionumberone.it and we would like to address two critical issues to you:

  1. When we work on the publication/editing of posts or update pages information, sometimes we face 524 Cloudflare errors. Searching the web, we came along with a Cloudflare support article in which it is suggested to exclude WordPress /wp-admin from the cache level.

We would like to try that out, but we want to know if that could fit the website htaccess configuration, since we added the following line of code, that prevent website to be cached (
Header set Cache-Control “private”
)

Should we cancel this line of code and set up Cloudflare as described here (Caching Static HTML with WordPress/WooCommerce – Cloudflare Help Center) ?

  1. Sometimes, by navigating the website, we open posts/podcasts pages and the content takes too much time to be loaded and we can’t understand why this is happening.

I attach here a link to a video on the Drive: here in the video the sessions goes perfectly, however sometimes some posts/pages seem not to be loaded (user sees just the header and no content below) and after navigating to other pages the post/page suddenly load, only after too many seconds. (navigazione radionumberone_ok_opera browser_23-09-2021.mp4 - Google Drive)

Could be something related to caching/cloudflare functionalities?

Thanks for your support.

I can speak to #1. A 524 is a timeout. Some servers and processes are so slow that they will time out (100 seconds on Cloudflare). There are no settings on Cloudflare, short of an Enterprise Plan’s ability to extend that timeout, to get around a 524.

The only workaround is a direct connection to the server, such as using a local Hosts file on your computer with the server’s IP address. Then you won’t face the 524 timeout while doing your admin work.

Hi Sdayman,
Thank you very much for your reply.

Why don’t you address the possibility to exclude the wp-admin from Cloudflare? There is some problem with that? (First, I missed to say that CLoudflare manage the DNS since domain radionumberone.it and WP appliction are not hosted on the same server).

So we have to choose whether to upgrade the Cloudflare plan to the Enterprise one and increase the timeout or to workaround that issue by working with file hosts.

However, if we opted for the second one (file hosts), would the editing on the website be published online in real time or will we need further operation?

Thanks again for you reply.
Andrea

Because you can’t. When you :orange: Proxy a record, it’s all or nothing.

It will be live immediately, just as if you never had the 524 error.

Hi Sdayman,
Thnaks for replying.

Ok, that’s clear. Not sure if the file host workaround could be the best proposal for the client, however we will consider that too.

First we will try to extend the timeout. Is there any server parameter do we have to rely on in order to set the timeout limit? Or it’s just about try and see if it works?

Thanks again

From the video you posted, may I ask are you using lazy-load feature for images, or some other via a JavaScript method?

Even as you scroll, I see the content apperas, which is even JavaScript or Ajax being loaded.
If you can check Developer Console (F12) → Network tab → XHR, if there appear ajax requests as you scroll, this is being generated, served and loaded directly from the origin host / server.

Plus, you have external content to be loaded such as audio from SoundCloud, etc.

WordPress and WooCoocommerce running without the cache, yes it could be an issue.

1 Like

Talking with a dev from our team, we were still wondering why this could not be possible.

https://support.cloudflare.com/hc/en-us/articles/200169526-Disabling-Cloudflare-features-on-admin-pages-for-content-management-systems-like-WordPress

Thanks again

A 100 second timeout isn’t a Cloudflare “feature”. It’s a limitation to maintain efficiency.

This issue has come up many times and it’s old news. Arguing isn’t going to change the 100 second limit.

Hi fritexvz,
We have checked the XHR and contents seem to be cached and released by cloudflare properly, as it should.

Actually, right now cloudflare cache is the only caching system active on the website.

We had tried to active SiteGround (wp installation is on SG hosting) memcache too, but it made conflicts with something in the website, so we prefer troubleshoot that on a staging website.

Thanks

Hi sdayman,

So the process described at the link is not possible? I didn’t get what you meant.

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