Last updated: February 28, 2024

Sometimes when you try to visit a web page, you’re met with an HTTP error message. It’s a message from the web server that something went wrong. In some cases, it could be a mistake you made, but often, it’s the site’s fault. 

Each type of error has an HTTP error code dedicated to it. If you try to access a non-existing page on a website it leads to a 404 error. 

Now, you might wonder, which are the most common HTTP errors that people encounter when they surf the Web? That is the question we’ll answer in this article. 

Google to the Rescue 

We asked Google “5 most common HTTP errors” and this is what it gave us: 

This is the result of millions of web users telling us themselves what errors they encounter the most.  

People who encounter errors when they visit websites want to know more about that error. They’ll probably go to the nearest search engine to do so. 

For this, Google’s search statistics should give us a pretty good idea of how the most common HTTP errors compare amongst themselves. It’s a great tool for estimating the “popularity” of search terms. 

Using Google Insights for Search we went through the above most common five HTTP error codes and compared them against each other. For this comparison, we chose the location “worldwide”. The period included all searches in 2023, and the type of search was limited to web search. When the dust settled from this little shootout, this is what we had: 

Note: Read our analysis on how Google collects data about the Internet and its users to understand better how Google works. 

The Top Five Errors, According to Google 

Here they are, listed and explained in reverse order, the five most common HTTP errors. Drumroll, please… 

5. HTTP Error 403 (Forbidden) 

This error is similar to the 401 error, but note the difference between unauthorized and forbidden. In this case, no login opportunity was available. This can happen, for example, if you try to access a (forbidden) directory on a website. 

To resolve an HTTP 403 error, the client or user should typically: 

  • Ensure they are using valid and authenticated credentials if required. 
  • Confirm they have the necessary permissions to access the resource. 

If IP blocking is suspected, ensure their IP address is not restricted.  

4. HTTP Error 401 (Unauthorized) 

This error happens when a website visitor tries to access a restricted web page but isn’t authorized to do so. The reason for this error is usually because of a failed login attempt. However, there can be more than one reason why this error occurs. Let’s look at the common ones: 

  1. Logging In: When a user tries to access a protected resource without being logged in, the server responds with a 401 error, prompting the user to provide their login credentials. 
  1. Client Authentication Required: This happens when the client that requests a certain resource from the server tries to request it without any authentication. In this case, the server indicates that the client must authenticate itself to get the requested resource by throwing the 401 error. This can happen if the client needs to provide a username and password or some other form of authentication token which is currently missing in the request. 
  1. Lack of Credentials: Another common reason for this error is that the client hasn’t provided valid authentication credentials in the request. These credentials are typically sent in the request header. For instance, methods like Basic Authentication (username and password), Bearer Token (OAuth 2.0), or API keys. 
  1. Invalid Credentials: In some cases even when the client does provide credentials, they could be invalid or expired. The server will then respond with a 401 error. In this case, the client should reauthenticate and send the request again with valid credentials. 
  1. Insufficient Permissions: Sometimes even with valid authentication credentials the server may return a 401 error. This maybe because the client doesn’t have the correct or necessary permissions to access this resource. In order to get through this, the client should request for the necessary permissions to access the resource. 

3. HTTP Error 404 (Not Found) 

Most people are bound to recognize this one. A 404 error happens when you try to access a resource on a web server (usually a web page) that doesn’t exist. Some reasons for this can be a broken link, a mistyped URL, or that the webmaster has moved the requested page somewhere else (or deleted it). To counter the ill effects of broken links, some websites set up custom pages for them (and some of those are really cool). 

Some of the common causes for this error include: 

  • The URL in the client’s request is misspelt or contains a typographical error. 
  • The requested resource has been deleted or moved to a different location. 
  • The server’s configuration is incorrect, preventing it from serving the requested resource. 
  • The resource never existed on the server. 

Some common techniques can help in resolving an HTTP 404 error quickly: 

  • Double-check the URL to ensure there are no typographical errors. 
  • Verify that the resource being requested actually exists on the server and is accessible at the specified URL. 
  • If the resource has been moved, update the URL accordingly. 
  • If the error persists on a website, the website owner or administrator should ensure that their server’s configuration is correct and that any deleted or moved resources are appropriately redirected or handled. 

If you aren’t managing 404 errors on your website properly, it can have a negative effect on your website’s search engine ranking. It can also hamper the overall user experience of your website. Ensure that you have a dedicated “Not Found” page that appears to your users and lets them know that the web page they’re trying to access is not available. 

2. HTTP Error 400 (Bad Request) 

This is basically an error message from the web server telling you that your application (e.g., your web browser) accessed it incorrectly or that the request was somehow corrupted on the way. This can happen due to one or more of the following reasons: 

  1. Malformed Request: The most common reason for a 400 Bad Request error is that the request is malformed. The client’s HTTP request does not conform to the HTTP protocol’s standards. This could be due to the following: 
  • Missing or improperly formatted headers. 
  • Invalid or missing request parameters. 
  • Unsupported HTTP methods (e.g., using POST when GET is expected). 
  • Incorrect content length or content type headers. 
  1. Security Concerns: A 400 error may be used by the server to protect against potential security threats. For instance, requests with extremely long URLs could be used for denial-of-service attacks. 

Some common techniques can help in resolving an HTTP 400 error quickly: 

  • Ensure the request’s syntax adheres to the HTTP standard. 
  • Verify that all required headers and parameters are included and correctly formatted. 
  • Ensure the correct HTTP method (GET, POST, PUT, DELETE, etc.) is used to access the resource 

1. HTTP Error 500 (Internal Server Error) 

The description of this error pretty much says it all. It’s a general-purpose error message for when a web server encounters some form of internal error. For example, the web server could be overloaded and therefore unable to handle requests properly. 

There are various reasons why an HTTP 500 error might occur, including: 

  • Software bugs or programming errors in the server code. 
  • Overloaded or under-resourced server infrastructure. 
  • Issues with the server’s configuration. 
  • Database connection problems. 
  • Unexpected exceptions or crashes in server applications. 

Resolving an HTTP 500 error typically involves troubleshooting and debugging on the server side. Actions that can be taken include: 

  • Checking server logs for detailed error information. 
  • Identifying and fixing software bugs or configuration issues. 
  • Ensuring that the server infrastructure is properly configured and adequately resourced. 
  • Addressing any database or application-specific problems. 

HTTP Error Code Cheat Sheet 

When dangling with HTTP errors, a cheat sheet can come in handy for figuring out which HTTP error you’re dealing with and what it really means. 

.As a primer, any HTTP status code in the form of 2XX is not erroneous, instead, it indicates a successful request and response. We can say the same thing for 3xx, however, from an end user perspective it might seem like an error code. Any status code in the form of 4xx or 5xx is definitely erroneous. 

Here’s the cheat sheet which summarises this: 

 Some Additional Comments on Website Errors 

We want to point out that all the error messages above are errors reported by the web server back to the visitor (that is the nature of HTTP errors; they come from the web server you are accessing). 

Needless to say, if you can’t access a website at all—for example, if it’s network that is down—you won’t get an HTTP error back. Your connection attempt will simply time out. 

We should add that the results from Google actually match our own data quite well. As you might know, we here at SolarWinds® Scopify® monitor websites and servers for a living (you can set up your own account by clicking here). When helping customers with problems, we have often come upon the dreaded (and pretty vague) HTTP error 500, “internal server error.” 

If you want to deliver a top-notch experience for your website users, learn how to analyze and improve page load performance



Source link

Related Post

Leave a Comment