HTTP 511 — Network Authentication Required
HTTP 511
Network Authentication Required
You need to log in to the network itself — this is a captive portal, not the site you asked for.
What 511 actually means
The response did not come from the site at all. Something between you and the internet — hotel Wi-Fi, an airport network, a coffee shop hotspot — is intercepting traffic until you accept terms or sign in. The code exists so that clients can tell a captive portal apart from a genuine site response, which matters because portals otherwise appear to be the site lying to you. It is defined as a 5xx precisely because the origin server never saw the request.
Common causes
- A hotel, airport or café captive portal awaiting sign-in
- A guest network requiring terms to be accepted
- A corporate network requiring authentication before internet access
- A paid hotspot whose session has expired
If you're just trying to view the page
- Open any plain http:// page — most portals cannot intercept HTTPS, which is why the login screen never appears when you only try secure sites
- On a phone, tap the Wi-Fi network name; both iOS and Android offer a "sign in to network" option that opens the portal
- Try visiting neverssl.com or captive.apple.com, which exist for exactly this purpose
- Forget the network and reconnect to trigger the portal detection again
If it's your site
- If you operate the portal, return 511 with a `Link` header to the login page rather than silently redirecting — silent interception breaks HTTPS and looks like an attack
- Do not use 511 on an origin server; it is specifically for intercepting proxies
- Client applications should handle 511 by prompting the user rather than retrying
Reference
- Status code
- 511
- Reason phrase
- Network Authentication Required
- Category
- 5xx — Server Error
- Cacheable by default
- No
- Defined in
- RFC 6585 §6
Common questions
- What does HTTP 511 mean?
- You need to log in to the network itself — this is a captive portal, not the site you asked for. The response did not come from the site at all. Something between you and the internet — hotel Wi-Fi, an airport network, a coffee shop hotspot — is intercepting traffic until you accept terms or sign in.
- How do I fix a 511 error?
- Open any plain http:// page — most portals cannot intercept HTTPS, which is why the login screen never appears when you only try secure sites
- Is 511 a client error or a server error?
- 511 is in the 5xx range, which means server error. The request was acceptable but the server could not fulfil it, so retrying later can succeed.
Related pages
- 500 Internal Server Error Something went wrong on the server and it has no more specific code to describe
- 502 Bad Gateway A proxy or gateway reached the server behind it and got back a broken response,
- 503 Service Unavailable The server is temporarily unable to handle the request, usually because it is ov
- 504 Gateway Timeout A proxy or gateway waited for the server behind it and gave up before an answer
- 524 A Timeout Occurred Cloudflare connected to the origin successfully but the origin did not finish re
- 521 Web Server Is Down Cloudflare could not connect to the origin server because it refused the connect
- 522 Connection Timed Out Cloudflare tried to open a connection to the origin server and never got a reply
- 520 Web Server Returned an Unknown Error Cloudflare reached the origin server but got back a response it could not make s
- 525 SSL Handshake Failed The TLS handshake between Cloudflare and the origin server failed.
- 526 Invalid SSL Certificate The origin server presented a TLS certificate that Cloudflare could not validate
- 530 Origin DNS Error A Cloudflare error shown alongside a 1xxx error code that carries the real expla
- 501 Not Implemented The server does not support the functionality needed to fulfil the request, usua