TapCub is live — analytics, insights and live chat, free on one platform
Glossary

HTTP 406 Not Acceptable: Causes and Fixes (Accept Headers and Bots)

What the 406 error code means, how Accept headers lead to it, a cause-and-fix table with a curl check, how it differs from 404 and 415, and why a 406 that only crawlers see can hide pages from search.

Xu An Reviewed by Lucas Hayes Also called 406 error Last updated Nov 22, 2026 Glossary

Quick answer

HTTP 406 Not Acceptable is a client error: the server has the resource but cannot produce it in any form the request's Accept, Accept-Language or Accept-Encoding headers allow, and will not send a default. A wildcard Accept: / avoids it. Crawlers that get 406 may not index the page.

What is the HTTP 406 Not Acceptable error?

HTTP 406 Not Acceptable is a client error status code. The server is saying: "I have the resource, but I cannot produce it in any form your request says it will accept, and I am not willing to send a different form instead." In the standard (RFC 9110, section 15.5.7), it means the target resource has no current representation acceptable to the user agent according to the content-negotiation headers in the request, and the server is unwilling to supply a default one.

MDN lists three request headers that drive this negotiation: Accept (media types such as text/html or application/json), Accept-Language and Accept-Encoding. If none of the representations the server can produce match what those headers allow, a strict server answers 406. Many servers do not: MDN notes that returning a 200 with a default resource that does not exactly match the client's preferences "may be preferable to sending a 406 response". So the code is uncommon on ordinary web pages, and when it does appear it usually points to a specific client sending a specific header. This entry explains how the negotiation works, the common causes and fixes, how 406 differs from similar codes, and why it matters when the client is a bot or crawler. For the more familiar missing-page error, see fix 404 errors.

How does content negotiation lead to a 406?

The client lists what it can accept, with optional weights called q-values. A type without a q-value has weight 1; weights run from 0 to 1, and 0 means "not acceptable". The server compares that list with the representations it has.

ClientTypical Accept headerWhat a server that only has HTML does
Browser, page navigationtext/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8Sends HTML (it matches the first entry; */* also matches)
Command-line tools such as curl and wget*/*Sends HTML (anything matches)
API clientapplication/jsonNo JSON available: may send HTML as a default, or answer 406
A client that asks only for XMLapplication/xmlNo XML available: 406 if the server is strict

The first two rows never produce a 406, because a wildcard (*/*) accepts anything. The last two show where it arises: a client asks for a narrow set and the server has nothing in that set.

A concrete request and response:

GET /report HTTP/1.1
Host: example.com
Accept: application/xml
HTTP/1.1 406 Not Acceptable
Content-Type: application/json

The Apache documentation describes the same decision as the last step of its negotiation algorithm: if no variant is acceptable to the browser, return a 406 with a body listing the available variants and set the Vary header. It also notes a language fallback: if a language match is impossible, Apache can ignore a subset (match en-GB against en documents) before giving up, and the ForceLanguagePriority directive can replace the error with the server's own choice of language.

What are the common causes of a 406, and how do you fix each?

CauseHow to recognise itFix
Client asks for a type you do not serveThe failing request has a narrow Accept (for example application/xml); */* worksServe the requested type, or return a default representation with a 200
API version in the headerAccept carries a version string the server does not knowCheck the documented version value; add the version if missing
Accept-Language or Accept-Encoding mismatchRequest asks for a language or encoding you do not haveAdd a fallback language or encoding, or ignore the header and send a default
Server configurationRewrite or negotiation rules (for example Apache MultiViews or type maps) pick no variantEnable a fallback such as ForceLanguagePriority, or remove the rule
A rule that rejects some clientsOnly certain user agents get 406; browsers do notCompare the request headers and your server logs for the rule that fired
Proxy or CDN in frontThe 406 appears at the edgeCloudflare states it does not generate 406 itself but passes it through from the origin; fix the origin

Reproduce before you change anything. With a command-line client you can send the exact header that fails and the same request with a wildcard:

curl -s -o /dev/null -w "%{http_code}\n" -H "Accept: application/xml" https://example.com/report
curl -s -o /dev/null -w "%{http_code}\n" -H "Accept: */*" https://example.com/report

If the first prints 406 and the second prints 200, the cause is negotiation. If both print 406, the cause is something else, such as a rule on the user agent or another header.

How is 406 different from 404, 415 and 400?

CodeMeaningWhose request is the problemExample
404 Not FoundThe resource does not exist at that addressThe URLA deleted page
406 Not AcceptableThe resource exists but not in an acceptable formThe response formats the client asked forAccept: application/xml against an HTML-only page
415 Unsupported Media TypeThe server cannot read the format of the request bodyThe body the client sentPosting XML to an endpoint that takes JSON
400 Bad RequestThe request is malformedThe syntaxA broken header

A simple test: 406 is about what the client wants back; 415 is about what the client sent. For a soft case where a missing page returns 200, see soft 404, and for the server-side class of errors, HTTP 500 error.

Why does a 406 matter for bots and crawlers?

A crawler is a client that sends its own headers, often different from a browser's. If your server returns 406 to a crawler because of its Accept header, the crawler sees an error and not a page. Google's documentation treats 4xx status codes other than 429 as meaning the content does not exist: URLs that return them are not indexed, URLs already indexed are removed, any content received with them is ignored, and crawl frequency gradually drops. So a 406 served to a search crawler can quietly remove pages from search while every browser test passes.

That is the specific risk: a 406 that only some clients see is invisible to the person testing in a browser. Two checks catch it: repeat the failing request with the crawler's user agent and a narrow Accept, and look at status codes in server logs by user agent rather than only at page views. If the codes show 406 for one crawler, return the page with a 200 and a default representation instead of rejecting the header. Related reading on crawling: crawl errors and bot traffic.

How do you work out whether your own site returns 406?

Sample data: a week of server logs shows 5,000 fetches by one search crawler, with these status codes.

StatusFetchesShare
200 or other below 4004,65093.0%
4042004.0%
5xx501.0%
4061002.0%
Total5,000100%

If you only count 404s and 5xx you account for 250 failures, and the total of 350 non-success fetches leaves 100 unexplained: those are other 4xx codes, here 406. The signal is in the arithmetic: success rate (93.0%) is lower than 100% by more than the 404 and 5xx shares combined (5.0%). Ask which URLs return the extra 2.0% and which Accept header they carry. Fix those URLs first, since they are pages the crawler wanted and was refused.

How can you see 406 responses to crawlers in TapCub?

TapCub does not show the 406 status itself on a page, and it does not fix server configuration. It can help you notice that something is wrong with crawler fetches, if server records are connected.

  1. Get server-side records in. The page script cannot supply a status code. Send server events or import server logs (All-platform analytics › Data › Data import takes Nginx and Apache logs) so that crawler fetches have a status. With script collection only, you do not see status codes or response time.
  2. Open crawl health. In Monitoring › Crawl health, the cards show total fetches, success rate, distinct pages, 404s and 5xx. Success means a status below 400, so a 406 lowers the success rate even though it has no card of its own. After a log import, 4xx and 5xx split out.
  3. Compare the numbers. Use the arithmetic above: if the success rate is lower than 404s plus 5xx explain, the remainder is other 4xx codes. Open the engine's row to see the pages that crawler fetched most.
  4. Turn on the alert. Switch on Crawl anomaly in notifications to be told when one engine's fetches in 24 hours fall below 30% of its 7-day daily average.
  5. Then fix it in your server. The reproduction commands above show the cause; the change happens on your server or CDN, not in TapCub.

Sources

Was this explanation clear?

We use your answers to fix and expand this page.

Xu An

Customer Experience Consultant

Writes about live chat, visitor conversations, and self-service, sharing practical ways to make customer communication clearer and more effective.

FAQ

Questions people ask

Short answers to the follow-up questions that come up most.

Still have a question?

Chat with the team behind TapCub — we usually reply within a few hours on business days.

What does a 406 error mean?

It means the server has the resource but cannot return it in a form the request says it will accept, based on the Accept, Accept-Language or Accept-Encoding headers, and it is unwilling to send a default. Many servers send a default with a 200 instead.

How do I fix a 406 Not Acceptable error?

Reproduce it with the failing Accept header and again with Accept: /. If only the narrow header fails, serve the requested type or return a default representation, add a fallback language or encoding, or remove the rule that picks no variant. If both fail, look at other headers or the user agent.

Is 406 a client or server error?

It is classed as a client error because it is a 4xx status and depends on the request headers, but the server decides to return it. Fixing it often means changing the server to be less strict about what it will send.

Does a 406 affect SEO?

Yes, if a search crawler receives it. Google treats 4xx codes other than 429 as meaning the content does not exist: it does not index those URLs, removes indexed ones and ignores the content. Check server logs for 406 by user agent.

See this number on your own site

Add one script tag for web and apps, and the first reports fill in within minutes.

See your data clearly. Find your growth.

Every click, backed by data. Install one line of code and see your first numbers in a minute.

No credit card · Free plans for analytics and chat · Cookieless analytics