HTTP 429 Too Many Requests vs 506 Variant Also Negotiates
HTTP 429 (Too Many Requests) is a 4xx Client Error response, while 506 (Variant Also Negotiates) is a 5xx Server Error response. 429 indicates that the user has sent too many requests in a given time (rate limiting). The response should include a Retry-After header. In contrast, 506 means that the server has an internal configuration error: the chosen variant resource is configured to engage in content negotiation itself.
Description
The user has sent too many requests in a given time (rate limiting). The response should include a Retry-After header.
When You See It
When hitting API rate limits or making too many requests too quickly.
How to Fix
Check the Retry-After header. Implement exponential backoff. Consider caching responses.
Description
The server has an internal configuration error: the chosen variant resource is configured to engage in content negotiation itself.
When You See It
Rare. Indicates a misconfigured server-side content negotiation loop.
How to Fix
Fix the server's content negotiation configuration.
Key Differences
429 is a 4xx Client Error response, while 506 is a 5xx Server Error response.
HTTP 429: The user has sent too many requests in a given time (rate limiting). The response should include a Retry-After header.
HTTP 506: The server has an internal configuration error: the chosen variant resource is configured to engage in content negotiation itself.
You encounter 429 when when hitting API rate limits or making too many requests too quickly.
You encounter 506 when rare. Indicates a misconfigured server-side content negotiation loop.
When to Use Which
For 429 (Too Many Requests): Check the Retry-After header. Implement exponential backoff. Consider caching responses. For 506 (Variant Also Negotiates): Fix the server's content negotiation configuration.