Site works from USA/CANADA, everywhere else receiving partial or full 521/520 errors


I’m trying to figure out what the issue is with a website I have migrated for a client onto his server. The website uses Wordpress and a DIVI theme, has WP Rocket implemented as the main cache system and the existing domain of the client has also been registered via Cloudflare from before.

After the migration, few optimizations were performed and the site was given the green light. However, soon after problems have risen up. And unusual ones on top of that. The site works perfectly fine from USA and CANADA - no issues are recognized, it loads within 2.5 seconds, no images are missing, no 521 or 520 errors are received.

However, from EUROPE, for example, various problems have been recognized. In some cases the site is not accessible with permanent 521 blocks. In other scenarios, the site loads, however has elements missing : such as images or certain scripts, which individually have 521 errors in network development tool logs.

Various things have been attempted within WP Rocket and Cloudflare options. Plugins had been deactivated and reactivated - no serious changes were noticed. In the end, Cloudflare was put into Development mode and - voila - the site was loading properly from EUROPE (and possibly other locations as well) - however, now, of course, the benefit of the CF cache were missing.

The website in question is :
In order to give you the “full experience” of the error, the development mode of CF has been deactivated.

The hosting provider says that they are not at fault, even though 521 and 520 errors would theoretically imply that something could / should be wrong at the hosting provider himself.

Has anyone experienced anything similar? Can you help us resolve this issue somehow? The hosting provider’s only advice was to completely remove Cloudflare - but the client already has several other things connected via CF and its DNS servers and it would again take 1-2 days to remove CF - which, I believe, should really be only the last possible option and move to assume.

One of the last 521 ERRORS was received via mobile access attempt with a Ray ID of : 66799c65b9fffc5d

Any help is greatly appreciated.
If you need any more information, please ask for it.

1 Like

I’m attaching an image for better clarification of 521 errors received even after the page opens / loads.

Update on things : A full ssl communication has been established via the CF certificate. A rule has been created to forward any http request to https (probably overkill).

Site still has major issues in Croatia, where its hosting provider and the client are located at. Errors now seem to be more 522 orientated.

Has anyone gotten any idea why the site is working off and on depending on regions?

I suspect your host is rate limiting or throttling Cloudflare:

A 522 error typically happens when Cloudflare requests to the origin (your webserver) get blocked. Review the suggestions in this Community Tip for troubleshooting ideas.

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