Random 520 errors started a few weeks ago

I’ve been using CloudFlare for years with no problems. But about a week ago my website started returning random 520 error pages. It feels like about every 50 pages.

There have been no changes to my webserver. It is a Centos/DirectAdmin/Apache setup.

Has something changed at CloudFlare?

Could it be related to this recent topic Sometimes a CF 520 error?

since a few days, we started getting 520 errors randomly all day.

it’s a cloudflare error.

Seriously? I believe that on my site the problem started two days ago and I didn’t understand why this was happening, mainly because I had never dealt with it before, and I also didn’t make any changes to my server.

The error happens randomly, very occasionally, to the point that it doesn’t interfere with the browsing experience. I found it strange because as soon as I press F5, the site is updated and back to normal, and there is no instability/slowness issue whatsoever.

Hi everyone,

Due to the number of 520s being reported in similar circumstances, we are escalating the issue to Cloudflare Support. The original incident should have been resolved and your issue may well be unrelated.

We recommend checking these troubleshooting tips, if you haven’t already.


If you have been through these thoroughly and are not seeing corresponding issues on your network/server and you have a ticket number with Cloudflare, please reply and post that #.

To enable efficient troubleshooting by support, please ensure you include the following on the ticket:

  • example URL(s) where you are seeing the error
  • Ray IDs from the 520 pages
  • output from a traceroute from any impacted user
  • output of example.com/cdn-cgi/trace - replace example.com with the affected domain.
  • Also include two HAR file(s) : one detailing your request with Cloudflare enabled on your website and the other with Cloudflare temporarily disabled - see How do I temporarily deactivate Cloudflare ?

So as part of https://community.cloudflare.com/t/random-520-errors/ we fixed an issue with origins silently ending a keepalive connection that was causing very rare 520 errors.

Thus we recommend testing again - if you still see 520s - make sure you follow the guidance in our community tip here:

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