What does HTTP status code 306 mean?
HTTP status code 306 is a reserved code that carries no active meaning. It was defined in an early draft of the HTTP/1.1 specification as “Switch Proxy”, intended to tell a client to use a specified proxy for subsequent requests. That behaviour was never adopted, the code was dropped from the standard, and 306 is now simply reserved so that it will not be reassigned.
When to use it in APIs
Never. There is no valid scenario for returning 306 from an API. Because the code is reserved and has no defined semantics, clients will not interpret it usefully. If you need to direct a client to a proxy, that is handled by proxy configuration and the 407 Proxy Authentication Required flow, not by a redirection status. For genuine redirects, choose an active 3xx code such as 307 or 308.
How it compares to other codes
- 300 Multiple Choices: An active redirection code indicating the resource has several representations for the client to choose from, unlike the dormant 306.
- 305 Use Proxy: The neighbouring code that actually addressed proxy use, though it too is now deprecated for security reasons.