In a recent discussion, Google’s Gary Illyes shed light on an important question – which is preferable: millions of 404 error pages or millions of 301 redirects? According to Illyes, both statuses have their benefits, and the decision ultimately depends on the specific situation.
Understanding Status Codes:
Illyes refers to the 404 and 301 responses as “status codes.” These codes are the server’s way of communicating with the browser or bot that made the webpage request. The World Wide Web Consortium (W3C) also recognizes them as status codes.
The Five Types of Status Codes:
- 1xx (Informational): The request was received, continuing process
- 2xx (Successful): The request was successfully received, understood, and accepted
- 3xx (Redirection): Further action needs to be taken in order to complete the request
- 4xx (Client Error): The request contains bad syntax or cannot be fulfilled
- 5xx (Server Error): The server failed to fulfill an apparently valid request
Understanding Error Pages:
While commonly known as “404 error pages,” these pages are not actually in error. Rather, they respond with a status code of 404 (page not found) because the requested webpage cannot be fulfilled. Unfortunately, the term “error” has led to the misconception that 404 responses are negative. In reality, they simply indicate that the requested page does not exist.
Choosing the Right Response Code:
Illyes emphasizes that the decision between a 301 redirect and a 404 response should be based on the individual publisher’s needs. If merging sites, redirecting old or outdated pages to new, relevant pages through 301 redirects is recommended. However, if the missing pages have no suitable matches, returning a 404 response is appropriate. Ultimately, the user experience should be the top priority when making this decision.
For more information on this topic, watch the Google SEO Office Hours starting at the 1:09 minute mark.