Getting HTTP 521 randomly on my website with the proxy option

Error 521: web server is down

Error 521 occurs when the origin web server refuses connections from Cloudflare. Security solutions at your origin may block legitimate connections from certain Cloudflare IP addressesOpen external link.

The two most common causes of 521 errors are:

  • Offlined origin web server application
  • Blocked Cloudflare requests

Resolution

Contact your site administrator or hosting provider to eliminate these common causes:

You can read more at Troubleshooting Cloudflare 5XX errors · Cloudflare Support docs.