Client Error

    HTTP 406 Not Acceptable

    The server cannot produce a response in a format the request said it would accept. On shared hosting it is very often a security rule blocking the request.

    Check a URL for HTTP 406

    Paste any URL to see whether it currently returns 406. Runs a live HTTP probe and follows redirects.

    TL;DR

    406 means the server will not answer in a form the request allows. For an API, fix the Accept header. For a website on shared hosting, a firewall rule is the usual cause, and the hosting provider can tell you which rule fired.

    What does HTTP 406 mean?

    HTTP 406 Not Acceptable is about content negotiation. The request's Accept, Accept-Language or Accept-Encoding headers list what the client is willing to receive, and the server has nothing that matches. In practice many 406 responses on ordinary websites do not come from content negotiation at all. They come from a web application firewall such as ModSecurity, which uses 406 to reject requests that match one of its rules.

    Common Causes

    • •A ModSecurity or other firewall rule on the server rejecting the request
    • •An API client sending an Accept header for a format the API does not offer, such as application/xml
    • •A request with an unusual or missing User-Agent or Accept header, common in scripts and bots
    • •A form or URL containing text that looks like an attack to the firewall

    How to Fix It

    1. 1.For an API: send an Accept header the API supports, usually application/json, or remove the header to accept anything
    2. 2.For a website: ask the host for the ModSecurity log entry for the request, which names the rule that blocked it
    3. 3.Have the host disable or adjust only that rule for the affected address, rather than turning the firewall off
    4. 4.If it started after a plugin or theme update, disable the plugin and test again
    5. 5.As a visitor, clear cookies for the site and try without browser extensions

    SEO Impact

    Google treats every 4xx code except 429 the same way: the content is taken not to exist. A page that keeps returning this code is dropped from the index, and a page that was never indexed will not be added.

    Monitor HTTP 406 with LemWatch

    Firewall rules often block monitoring and crawlers before they block people. If a monitored page returns 406 while it loads in your browser, the firewall is refusing the checker's request and may be refusing search engines too.

    Frequently Asked Questions about HTTP 406

    Why do I get 406 on WordPress?

    On shared hosting it is nearly always ModSecurity. A plugin's request, a long URL or the text in a form matches a firewall rule, and the server answers 406. The host can identify the rule from its log and make an exception.

    Free Website Tools

    Check your site for common issues that cause HTTP errors: