Hostwinds Tutorials

Search results for:


Table of Contents


500 Internal Service Error
What causes a 500 internal server error?
502 Bad Gateway
What causes a 502 Bad Gateway error?
400 bad request error
401 Unauthorized error
403 Forbidden error
404 Not Found error

HTTP Error Codes

Tags: http errors 

500 Internal Service Error
What causes a 500 internal server error?
502 Bad Gateway
What causes a 502 Bad Gateway error?
400 bad request error
401 Unauthorized error
403 Forbidden error
404 Not Found error

Many different error codes can be presented from a server when things go wrong. These can help troubleshoot the leading cause of the issue and fix the problem as soon as possible. The first digit of the status code a website gives allows us a broad understanding or group of what the issue may be.

  • 1## – These codes are usually informational and not used to identify errors.
  • 2## – These codes represent a success, generally in regards to connecting to the server.
  • 3## – These codes imply a permanent or temporary redirection of the page you are visiting.
  • 4## – This is a client error code and means typically, the error is caused by the user connecting to the server.
  • 5## – This is a server error code, letting the user know that the cause of the issue is on the server's side.

500 Internal Service Error

A 500 error often will say something similar to this:

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator, webmaster@example.com, and inform them of the time the error occurred and anything you might have done that may have caused the error. More information about this error may be available in the server error log.

What causes a 500 internal server error?

When a site prompts a 500 Internal Server Error to show, it means it knows there is a problem, but it is still unable to deliver on the request for an unknown reason. This error often comes from a problem in the configuration of a script, and unfortunately, it won't provide any details about the situation.

Common causes for the 500 error:

  • Problems with the .htaccess file
  • Problems with the php.ini file
  • Permissions not set properly
  • Problems with script requests
  • Ownership not set properly

It can be tricky to find the exact cause, but you should first look in cPanel's error logs. If that doesn't help you identify the problem, don't hesitate to contact Hostwinds technical support to help you get it fixed.

502 Bad Gateway

A 502 error presents when a server receives an invalid response from an inbound server.

What causes a 502 Bad Gateway error?

When a site prompts a 502 Bad Gateway Error to show, it means that the server is a gateway or a proxy that forwards the request to another backend server and that it is not receiving a valid response to fulfill the request.

Common causes:

  • Your backend servers are not healthy (From where the HTTP Requests are forwarded).
  • The reverse proxy is misconfigured, or the backends specified* are invalid.
  • The connection between the backend servers and the reverse proxy server is unhealthy and needs a check-up, or the firewall does not allow traffic from one.
  • The web application is listening on a socket in the incorrect location, or it has improper permissions.

It can be tricky to find the exact cause, but you should first look in cPanel's error logs. If that doesn't help you identify the problem, don't hesitate to contact our technical support to help you get it fixed.

400 bad request error

A 400 Bad Request Error is another standard HTTP status code. You will see this when the site receives a corrupt or problematic request to do something, such as run a script or display the content of a page.

If you see a 400 bad request error, first make sure you're trying to access the correct URL. If so, try to clear your cookies and your cache. If that doesn't work, clear your DNS cache. If all else fails, contact us and let us help you get it fixed.

401 Unauthorized error

The 401 Unauthorized Error is another HTTP status code, except that the server's user trying to access the specific resource will not authenticate. While not caused by having different permissions on the file, it can happen when a user does not enter the correct username and password in the .htpasswd file on the server in that same directory.

The .htpasswd file cannot be seen from the browser, as most configurations hide these types of files by default.

To resolve this error, ensure that you enter the correct username and password you may have set up in the .htpasswd file.

403 Forbidden error

The 403 Forbidden Error occurs when the user requests a resource from the server, where the user or server does not have access to read or execute the file. It is commonly recommended for files to have their permissions set to 755 for directories and 644 files. Meaning that the user of the directory can read, write, and execute. The assigned group of the files can read and execute but not write. Everyone not included can read and execute the files but not write.

You can change file permissions on a Linux server within cPanel, or you can modify the file permissions from the command line.

404 Not Found error

Multiple things can cause the 404 Not Found error. This error code will show up because the resource or file that a user is looking for is not there. Coding of the site can cause this, the code of someone else's site, or by incorrectly typing in the wrong URL.

To fix this, if it is a coding issue on your site, go through your code, usually using the built-in find feature in most text editors, and find the link that is leading your users to an invalid page and correct it. For the most part, these are typically just Typos.

If you have any questions or need assistance, please get in touch with us through Live Chat or submit a ticket with our Technical Support team.

Written by Hostwinds Team  /  December 13, 2016