When a server fails to supply information, it returns an HTTP 406 error. When customers enter a question and the server fails to supply the requested content material or format, it responds with standing code 406. For web site guests, the difficulty could be attributable to defective browser settings, extensions, cookies, or community instruments. For builders and web site directors, the error could also be attributable to strict server guidelines, content material negotiation, safety software program, or CMS settings.
For on a regular basis web customers, it might trigger looking inconsistencies, whereas for builders it might injury person expertise, search engine optimization rankings, and cut back ongoing visitors. Nonetheless, a 406 error isn’t everlasting. This information explains repair a 406 error from each side. It additionally explains detect HTTP response code 406, what causes it, and stop it from occurring once more.
Precisely Detect and Repair 406 Errors With IndeedSEO
What’s a 406 Error?
An HTTP 406 Not Acceptable error is a response standing code. When a person varieties a request, your browser sends it to the server. This request accommodates particular directions referred to as settle for headers, which inform the server precisely what you requested. With this info, the server can perceive your preferences in language, format, and media. Generally a server can’t perceive your request or fails to give you the requested particulars. At such occasions, relatively than exhibiting you obscure info, it shows the error code.
You may even see messages similar to:
- 406 Not Acceptable
- HTTP Error 406
- Error 406 – Not Acceptable
- HTTP 406 Not Acceptable
- Request Not Acceptable
The requested useful resource is just able to producing content material not acceptable in response to the Settle for headers.
What Causes a 406 Error?
An HTTP 406 Not Acceptable error could be attributable to a number of content material and web site points. Among the core circumstances that trigger this error are as follows:
Mismatched Settle for Headers:
That is when a consumer requests a particular content material sort. It may be a code for XML that the server will not be programmed to ship. In such circumstances, there isn’t any response.
Strict Content material Negotiation:
This occurs when the server lacks a fallback mechanism. The server strictly rejects requests as a result of it doesn’t match any accessible format, inflicting a 406 error.
Internet Software Firewall (WAF) Guidelines:
Safety modules like mod_security on Apache suspect any uncommon request. When there’s any such enter, the server can consider it as malicious work. It can block it with a 406 response.
Language or Encoding Mismatches:
This difficulty arises when any consumer’s Settle for-Language or Settle for-Encoding doesn’t align with the server. It fails to supply a response and causes an error.
Browser Extensions or Safety Instruments:
Sure extensions or VPNs result in HTTP modification, or they strip request headers. This corrupts the enter and stops communication between consumer and server.
The best way to Detect HTTP Response Code 406

To detect an HTTP Response Code 406 (Not Acceptable), you might want to search for cases the place an internet server rejects a consumer’s request. Since it may be attributable to a number of points, the detection strategies rely completely on at what level you’re analyzing your difficulty.
Test the Browser Developer Instruments
Most trendy browsers embody developer instruments. To verify the response:
- Open the affected webpage.
- Proper-click and choose Examine.
- Open the Community tab.
- Reload the web page.
- Discover the failed request.
- Test its HTTP standing code.
- Search for 406 Not Acceptable.
You may also examine the request and response headers. This is likely one of the best methods for builders to know what is occurring.
Use an HTTP Standing Code Checker
An HTTP standing code checker can check a URL and present the response returned by the server. That is helpful if you need to verify whether or not a web page is returning standing codes. A standing checker also can assist establish whether or not the error impacts one URL or a number of pages.
Test Server Logs
Web site directors can assessment server logs to search out 406 responses.
Logs could present:
- Requested URL
- Shopper IP
- Request methodology
- HTTP standing
- Person agent
- Referrer
- Request time
- Safety rule triggered
Server logs are significantly helpful when the error happens solely underneath sure circumstances.
Take a look at the URL With Completely different Requests
Builders can check the identical URL utilizing completely different request headers. For instance, altering the Settle for header will help decide whether or not content material negotiation is accountable for the error.
The best way to Repair a 406 Error as a Web site Customer or Person
As an internet site customer or person, the error could be fastened with some troubleshooting. To grasp the entire course of, right here is a straightforward step-by-step course of you possibly can strive.
Easy Steps to Repair a 406 Error
Test the URL:
Guarantee your web site handle is right. If there are any further characters or typos, your URL might be corrupted. Additionally verify for further extensions in your commonplace web page hyperlink in order that it doesn’t confuse the server.
Clear your browser information:
In case your server has any outdated cache and cookies, it impacts the request headers. Make certain your browser is optimized, after which refresh the web page.
Strive one other browser:
Recheck your enter in different browsers. Make certain to verify in an incognito/personal window as properly. If the web page hundreds usually, your principal browser is inflicting the issue. It may be associated to a strict setting or extension points.
Disable extensions, VPNs, or proxies:
Sure blockers, VPN, or antiviruses alter the request headers. Test the outcomes after you could have turned them off to establish the difficulty.
Use a special machine:
Take a look at the identical hyperlink on a number of gadgets. Use your cell phone, PC, or laptop computer to make sure that the difficulty will not be due to your alternative of machine.
The best way to Repair a 406 Error as a Developer or Internet Administrator
Builders can examine the request, server configuration, and software code to search out the error. Begin your course of as follows:
Test the Settle for Header
The Settle for request header informs the server which sort of media could be processed. If the endpoint can not generate the requested format, it could return a 406 response. Test whether or not the requested format is supported by the appliance.
Evaluation Content material Negotiation
Content material negotiation permits a server to pick out the very best illustration of a useful resource.
Evaluation server guidelines associated to:
- MIME varieties
- Language
- Character encoding
- Media varieties
- File extensions
- Settle for headers
Incorrect content material negotiation guidelines could cause legitimate requests to obtain 406 responses.
Test Apache Configuration
If the web site makes use of Apache, examine configuration information similar to .htaccess and the principle Apache configuration.
Search for guidelines associated to:
- ModSecurity
- Rewrite guidelines
- MIME varieties
- Content material negotiation
- Request filtering
- Entry management
Watch out when modifying server configuration. A small change can have an effect on a number of URLs.
Test Nginx Configuration
For Nginx web sites, assessment the server block and associated configuration information. Test for customized guidelines that may block request headers. Assess URL patterns and content material varieties to check the configuration earlier than reloading Nginx.
Evaluation ModSecurity Guidelines
ModSecurity is usually used as an internet software firewall. It’s used to guard web sites towards malicious visitors. Generally these reputable requests could be blocked by safety guidelines.
Test your ModSecurity audit logs.
If a rule is inflicting the 406 response, verify why it’s displaying the error earlier than altering or disabling it. Don’t flip off your total safety system for one error. As an alternative, regulate particular guidelines to assist and defend your website.
Test WordPress Plugins and Themes
If the error happens on a WordPress web site, verify not too long ago put in or up to date plugins. Safety, firewall, caching, search engine optimization, and redirect plugins can typically have an effect on requests.
You may troubleshoot by:
- Backing up the web site.
- Quickly disabling not too long ago modified plugins.
- Testing the affected URL.
- Re-enabling plugins one after the other.
- Checking the theme if the difficulty continues.
If disabling a plugin fixes the issue, examine its settings earlier than changing it.
Test API Request Headers
For APIs, evaluate a working request with the request returning 406.
Evaluation:
- Settle for
- Content material-Kind
- Authorization headers
- Question parameters
- Request methodology
- API model
- Response format
Make certain the API documentation matches the request being despatched by the consumer.
Precisely Detect and Repair 406 Errors With IndeedSEO
Conclusion
A 406 Not Acceptable error often means there’s a mismatch between a consumer request and server response. This weblog discusses a number of steps to resolve the 406 Error for each customers and builders to make sure a protected and safe looking expertise. Nonetheless, if you wish to accomplice with an knowledgeable digital advertising company to handle your website, contact IndeedSEO. Test your web site’s HTTP standing codes with IndeedSEO and clear up technical points early.









