505 HTTP Version Not Supported
The server does not support the HTTP protocol version used in the request.
Meaning & Description
Common Causes
- Using highly outdated tools, legacy hardware, or custom IoT devices that only speak HTTP/1.0.
- Hand-typing raw HTTP requests via telnet or netcat and making a typo in the protocol version.
- Misconfigured load balancers attempting to downgrade traffic to an unsupported version.
How to fix a 505 error
- Inspect the raw request headers to see exactly which HTTP version is being sent (e.g., HTTP/1.0 vs HTTP/1.1).
- If using cURL, use the `--http1.1` or `--http2` flags to explicitly define the protocol version.
- Ensure your server configuration (Nginx, Apache) is set up to accept the protocol version the client is using.
Browser & SEO Behaviour
Browser Behavior
Modern browsers will never trigger this organically, as they automatically negotiate the highest supported protocol (HTTP/2 or HTTP/3) with a fallback to HTTP/1.1.
SEO Impact
No impact unless the server is misconfigured and rejecting standard HTTP/1.1 or HTTP/2 requests, which would block crawlers entirely.
CDN Behavior
CDNs fully handle protocol negotiation. They may serve HTTP/3 to the client while speaking HTTP/1.1 to the origin server. A 505 is exceedingly rare behind a CDN.
Code Examples
HTTP/1.1 505 HTTP Version Not Supported
Content-Type: text/plain
HTTP/1.1 is required. HTTP/1.0 is no longer supported.app.use((req, res, next) => {
if (req.httpVersion === "1.0") {
return res.status(505).send("HTTP/1.1 or higher is required.");
}
next();
});package main
import "net/http"
func handler(w http.ResponseWriter, r *http.Request) {
if r.ProtoMajor < 1 || (r.ProtoMajor == 1 && r.ProtoMinor == 0) {
http.Error(w, "HTTP/1.1 or higher is required", http.StatusHTTPVersionNotSupported)
return
}
w.WriteHeader(http.StatusOK)
}
func main() {
http.HandleFunc("/", handler)
http.ListenAndServe(":8080", nil)
}# Forcing an ancient HTTP/1.0 request to a strict modern server
curl -0 https://api.example.com/Raw HTTP Response Example
HTTP/1.1 505 HTTP Version Not Supported
Content-Type: application/json
{
"error": "HTTP Version Not Supported",
"message": "This API requires HTTP/1.1 or HTTP/2."
}Real-world Examples
Frequently Asked Questions
Can a modern web browser trigger a 505 error?
Practically never. Modern browsers (Chrome, Firefox, Safari) always speak HTTP/1.1, HTTP/2, or HTTP/3, which are universally supported by modern web servers.
What is the difference between HTTP/1.0 and HTTP/1.1?
HTTP/1.1 introduced persistent connections (keep-alive), chunked transfer encoding, and the mandatory Host header. Many servers reject HTTP/1.0 because it lacks these critical features.
Is 505 an error with the client or the server?
It is technically a server error (5xx) because the server is declaring its inability or unwillingness to fulfill the request using the client’s protocol, but it is triggered by the client using an outdated protocol.
Did You Know?
The 505 status code is one of the rarest HTTP errors encountered in normal web browsing.
If a server requires a client to upgrade to a newer protocol (like moving from HTTP/1.1 to HTTP/2), it should technically return a 426 Upgrade Required, not a 505.
Developer Tips
- You generally do not need to implement this manually in application code; your web server (Nginx, Apache, IIS) handles HTTP protocol version validation natively.
- If you are building a custom raw TCP/HTTP server, ensure you gracefully handle legacy HTTP/1.0 requests or explicitly return a 505 with a clear explanation.
Interview Questions
These are questions you might face in a backend or API design interview that touch on HTTP 505.
When would a server return a 505 HTTP Version Not Supported?
When a client attempts to make a request using an HTTP protocol version the server refuses to support, such as a legacy HTTP/1.0 request sent to a strict HTTP/1.1+ API.
Common Interview Mistakes
- Confusing 505 with 426 Upgrade Required. 426 means "you must upgrade your connection using the Upgrade header." 505 means "I don't speak the version you just used at all."