DEV Community

Cover image for Error 404 : Page not Found
Rahul Kumar
Rahul Kumar

Posted on • Edited on

Error 404 : Page not Found

When you click on a link, but instead of arriving to the site you want, an error message appears, stating that the page you requested is unavailable. It should be something along the lines of '404 Not Found.'

A 404 error is an HTTP status code that indicates that the website's server does not have the page you were searching for.

When website content is deleted or relocated to another URL, an error 404 message is commonly shown.

The 404 status code is the most common HTTP status code.

What are HTTP status codes?

A server answer to a browser's request is an HTTP status code. When you visit a website, your browser makes a request to the server, which the server responds to with a three-digit code called the HTTP status code.

  • These status codes represent a communication between your browser and the server over the Internet. They convey if things are fine😊, touch-and-go👍, or if something is wrong😕 between them.

Common HTTP status code classes:

http status codes

Each three-digit status code starts with one of five integers, ranging from 1 to 5, and is written as 1xx or 5xx to signify status codes in that range. For example, 200, 301, 404, 500, and so on...

100–199 - Informational responses: The server is thinking through the request.
200–299  - Successful responses: The request was successfully completed and the server gave the browser the expected response.
300–399  - Redirection: You got redirected somewhere else.
400–499  - Client errors: Page not found. The site or page couldn’t be reached. 
500–599  - Server errors:  A valid request was made by the client but the server failed to complete the request.
Enter fullscreen mode Exit fullscreen mode

HTTP Status Code 200 - OK
The 200 (OK) status code indicates that the request has succeeded. This is your ideal status code for your normal, everyday, properly functioning page.

HTTP Status Code 301 - Permanent Redirect
A 301 redirect should be utilized any time one URL needs to be redirected to another permanently.
Visitors and bots who come on that page will be sent to the new URL through a 301 redirect.

HTTP Status Code 500 - Internal Server Error
This status code indicates a server fault rather than a problem with pages missing or not found. A 500 error is a common server issue that will prevent visitors from accessing your website.

HTTP 404 errors can decreases a website’s ranking and reputation.
Once the crawlers have determined that 404 codes are being returned for a large number of queries, they will proceed to the next step. This might result in a significant drop in the number of visitors to the website.

👉Read more here (RFC 7231)

Getting bored😑
Try this once :https://http.cat/[status_code]
For example :
https://http.cat/404
https://http.cat/450
https://http.cat/500


Top comments (0)