TrueURL
5xx Server Error Non-standard code (Cloudflare)

520 Web Server Returned an Unknown Error

Cloudflare-specific: the origin server returned an empty, unknown or unexpected response, for example after a crash or a reset connection.

Reason phrase
Web Server Returned an Unknown Error
Redirect
No
Cacheable by default
No

520 is a Cloudflare-specific code. Cloudflare returns it when the origin web server sends back an empty, unknown or unexpected response that Cloudflare cannot pass on. It is the catch-all for origin responses that do not fit any of the other 52x codes.

Typical triggers are an origin that crashes or resets the connection after Cloudflare has connected, responses without a valid status line or headers, response headers that exceed Cloudflare's size limits (often because of too many or too large cookies) and origin firewalls that cut off connections from Cloudflare's IP addresses. An nginx return 444 on the origin also reaches visitors as a 520.

Cloudflare's error page shows a Ray ID; the origin's error and access logs from the same moment usually reveal the cause. Over HTTP/2 and HTTP/3 there is no reason phrase, so you only see the number.

Example response

HTTP
HTTP/1.1 520 Web Server Returned an Unknown Error
Date: Fri, 06 Nov 2026 10:15:32 GMT
Content-Type: text/html; charset=UTF-8
Connection: close
X-Frame-Options: SAMEORIGIN
Referrer-Policy: same-origin
Cache-Control: private, max-age=0, no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Expires: Thu, 01 Jan 1970 00:00:01 GMT
Server: cloudflare
CF-RAY: 8f3a1b2c4d5e6f70-FRA

SEO and redirect checking

Search engines treat 520 like any 5xx error: crawling slows down, and persistent errors lead to deindexing. 520s are often intermittent, so check affected URLs several times, for example with the Bulk Redirect Checker, and compare the result with a direct request to the origin.

Common causes and use cases

  • The origin application crashed or closed the connection without sending a response.
  • The response headers are too large, for example because of many Set-Cookie headers or large tokens.
  • An origin firewall or security plugin resets connections from Cloudflare's IP ranges.
  • The origin sends a malformed or empty HTTP response, for example because of a faulty HTTP/2 configuration.

URL Redirect Checker

See every status code a URL returns, hop by hop, with the free TrueURL redirect checker.