Bad Request error code 400 is an HTTP status code that denotes a problem with an invalid request. As a result, the server is unable to comprehend and process it. These poor requests are frequently the result of incorrect request syntax, misleading route framing, or fraudulent request routing. If you get this message when browsing the web, there’s a lot you can try. Unfortunately, in most cases, the problem is caused by the website server. In that situation, only the site owner has access to methods for fixing it. This guide will help you fix a 400 bad request error using over a dozen methods. But first, let’s analyze what can be the root of the problem.
What causes 400 Bad Request errors?
There are a few reasons the 400 error can appear, so here are common ones:
- Request headers are too large
- The server is unable to process the request due to malformed syntax
- The request URI (Uniform Resource Identifier) is longer than the server can interpret
- POST content is larger than what the server can accept
- Incorrectly formed cookies on the client side
These are some of the most common sources of the 400 HTTP error message that suggest a potential fix. This error may also be caused by your browser rather than the website. For example, if you get this message in Firefox, you likely have cookies disabled. Thus, you can try to fix a 400 Bad Request error in several ways, so let’s check them one by one
1. Check for incorrect spelling or wrong domain name in the URL
One of the most common causes of this error is simply entering the wrong URL (Uniform Resource Locator). This can happen if you make a typo when typing in the address or trying to access a website that no longer exists. After checking, if you’re sure that it’s correct, try accessing the site from another browser or device. This will rule out potential problems with your computer or internet connection.
2. Clear your browser’s cookies and cache
Cookies are small pieces of data that websites store on your computer. They’re used for various purposes, such as keeping you logged in or remembering your preferences. Sometimes, these cookies can become corrupted and cause problems. If you’re getting a 400 Bad Request error, it’s worth trying to clear your cookies and cache. This can usually be done from within your browser’s settings menu. Once you’ve done this, try accessing the website to see if the problem has been resolved.
3. Use a different internet browser
If you’re still getting a 400 Bad Request error, something could be wrong with your browser. In this case, the best thing to do is try accessing the website using a different browser. For example, if you’re using Chrome, try opening the site in Firefox or Edge. This will rule out any potential browser-specific problems.
4. Disable browser extensions
If the problem doesn’t go away, it could be because of a browser extension that you have installed. These extensions can sometimes interfere with website requests and cause problems. To rule out this possibility, try disabling all your browser extensions and re-accessing the website. Then, if the problem disappears, you can enable your extensions one by one until you find the culprit.
5. Fix 400 Bad Request error by resetting browser settings
Resetting your browser settings is also worth trying. This will usually fix any problems caused by incorrect or outdated settings. To do this in Chrome:
- Select the menu icon and select “Settings.”
- Scroll down to the bottom of the page and select “Advanced.”
- Press “Reset” and then “Reset” again to confirm.
In Firefox, do this:
- Go to the menu icon and select “Options.”
- Select “Advanced” and then “Restore defaults.”
For Edge, open the menu icon and:
- Select “Settings.”
- Select “Choose what to clear”, then select everything.
- Press “Clear” button to confirm.
6. Check proxy settings
If you’re behind a proxy server, it could interfere with your connection and cause this error. To check your proxy settings in Chrome:
- Proceed to the menu icon and select “Settings.”
- Scroll down to the bottom of the page and select “Advanced.”
- Choose “Open proxy settings.”
For Firefox, go to the menu icon and:
- Pick “Options.”
- Choose “Advanced” and then “Network.”
- Select “Settings” and then ensure that “No proxy” is selected.
In Edge, choose the menu icon and:
- Go to “Settings.”
- Pick “View advanced settings” and move down to the “Proxy server” section.
- Ensure the “Use a proxy server” switch is turned off.
7. Temporarily turn Firewall off
If you have a firewall enabled on your computer, it could be blocking website requests and causing 400 Bad Request errors. To disable your firewall on Windows:
- Type “firewall” into the Start Menu and select “Windows Defender Firewall.”
- Select “Turn Windows Defender Firewall on or off.”
- Next, select “Turn off Windows Defender Firewall (not recommended)” and then press “OK.”
Turning off the firewall on Mac works this way:
- Open the System Preferences app and select “Security & Privacy.”
- Select the “Firewall” tab and the “Turn Off Firewall” button.
8. Using another DNS server to fix the 400 Bad Request error
If you’re still getting 400 Bad Request errors, try changing the DNS server. This will usually fix any problems caused by your current DNS server being down or unavailable. To change your DNS server in Windows:
- Type “control panel” into the Start Menu and select “Control Panel”.
- Select “Network and Internet” and then “Network Connections.”
- Right-click your active network connection and select “Properties.”
- Select “Internet Protocol Version 4 (TCP/IPv4)” and then choose “Properties.” Opt for “Use the following DNS server addresses” and enter 8.8.8.8 for the Preferred DNS server and 8.8.4.4 for the Alternate DNS server.
- Press “OK” to save your changes.
Change your DNS server on macOS
Switching your DNS server for Mac works this way:
- Open the System Preferences app and select “Network.”
- Select your active network connection and click “Advanced.”
- Select the “DNS” tab and enter 8.8.8.8 for the Primary DNS server and 8.8.4.4 for the Secondary DNS server.
- Press “OK” to save your changes.
9. Restart your modem or router
Another source of the problem could be your router or modem. To fix this, restart those devices and try loading the website again. This could (and should) fix any connection problems causing the 400 Bad Request error.
10. Configure the correct date and time on your machine
If your computer’s date and time are not set correctly, it could manifest as a 400 Bad Request error. To fix this, open the Date and Time settings on your computer and make sure that the date and time are set correctly. Once you’ve done this, try loading the website again to see if anything changed.
11. Check for malware
Malware can cause all sorts of problems on your computer. If you think that malware might be causing 400 Bad Request errors on your computer, you can use an anti-malware or antivirus tool to scan your computer and remove any suspicious files. Do check the pros and cons of antivirus beforehand.
12. Contact the website owner
Tried the methods above and continue to get the 400 Bad Request error? The problem likely lies with the website itself. In this case, your next move is to contact the website owner and inform them about the issue. They should be able to take a look and fix the problem on their end.
13. Check for server-side issues
If you’re a website owner, and you see 400 Bad Request errors, it’s worth checking your server logs. This will usually give you clues as to what’s causing the problem. For example, if you see that a particular URL is causing the error, you can try redirecting that URL to another page. Alternatively, if you see a problem with POST data, you can try increasing the size limit for POST data in your server settings.