What it means
Cloudflare-specific: the origin server refused the connection.
Common causes
- Web server process stopped
- Origin firewall blocks Cloudflare IPs
- Server listening on the wrong port
How to fix it
As a client or visitor
Retry later; the site's server is down or blocking Cloudflare.
As the site or API owner
Make sure the web server runs and accepts connections on ports 80/443 from Cloudflare IP ranges.
Example response
HTTP/1.1
HTTP/1.1 521 Web Server Is Down
Date: Tue, 07 Oct 2025 09:30:00 GMT
Server: nginx
Content-Length: 0 Specification
Not in the IANA registry; used by Cloudflare. Cloudflare
FAQ
› 521 vs 522?
521: connection refused quickly. 522: no reply before the timeout.
› Can security plugins cause 521?
Yes. Rate limiters such as fail2ban may ban Cloudflare's IPs.