Connect with us

SEO

301 Redirect or “404 Error Pages”?

Published

on

301 Redirect or "404 Error Pages"?

Google’s Gary Illyes answered a question about which is less worse to use, millions of 404 error pages or 301 redirects. Gary’s answer cleared the air about how to think about each status code.

The question was simple:

“What is less harmful: having millions of 404 error pages or millions of 301 redirects, where sold product pages redirect to the parent listing page?”

The answer was also simple, although it could have gone into more detail.

This is Gary’s answer:

“404 status codes are completely harmless, and so are 301.

You need to decide what’s better for your scenario for and fly with that.”

Advertisement

Status Codes

Gary uses the phrase “status codes” to refer to the 404 and 301 responses.

They are both responses by a server to a request for a webpage (that was made by a browser or bot).

When a browser goes to a webpage, what it’s doing is requesting a webpage from the server.

The server responds to the browser request with a message communicating the status of that request.

That’s why Gary called the 301 and 404 codes status codes.

Because they are responses (from the server to the browser), they’re also called response codes.

Advertisement

But technically, they are status codes, because the creators of the HTML standards, the World Wide Web Consortium (W3C), refers to them as status codes.

There are five kinds 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”

Advertisement

Error Pages/Error Codes

The question that was asked referred to “404 error pages,” likely because they are commonly referred to as 404 errors.

But the pages themselves are not in error.

What’s happening is that the request for missing webpages “cannot be fulfilled.”

There is an error in that the page page is not found. But the server only responds with a status code, 404 (page not found).

The common use of the word “error” to refer to the 404 has led to the mistaken belief that 404 responses are bad.

But that’s incorrect, the 404 response is neither bad nor good, it’s just a response that the page is not found.

Advertisement

According to the W3C:

“The 404 (Not Found) status code indicates that the origin server did not find a current representation for the target resource or is not willing to disclose that one exists.

A 404 status code does not indicate whether this lack of representation is temporary or permanent;…”

Another trustworthy and authoritative HTML resource, the Mozilla Web Docs, defines the 404 status code like this:

“The HTTP 404 Not Found response status code indicates that the server cannot find the requested resource.

…A 404 status code only indicates that the resource is missing: not whether the absence is temporary or permanent.”

All of that explains why Gary Illyes said that “404 status codes are completely harmless…

How to Choose Between 301 and 404 Response Code

Gary also said that the individual publisher needs to choose what works best for them.

Advertisement

Webpages go missing for a variety of reasons.

If the page is missing because two sites were merged, a publisher can 301 redirect old or outdated pages to the new pages that are similar in topic.

But if the pages have no similar topic match then those pages can become 404 responses, saying that the page is absent.

One can use a 410 status code to indicate the removal is permanent, but Google essentially treats the 404 and 410 almost the same.

In the end, when in doubt, think about what works best for the user.

For example, if you are merging a site that’s about Topic K into a bigger site that’s about Topic A – Z, then it may make sense to do a one-to-one redirect to pages in the bigger site that are about Topic D.

Advertisement

The rest of the pages that don’t have a one-to-one match can be redirected to the main category page for Topic D in the bigger site.

Or as Gary said, “You need to decide what’s better for your scenario…

Watch the Google SEO Office Hours at the 1:09 minute mark:

Featured image by Shutterstock/Asier Romero

 

Advertisement

 



Source link

Keep an eye on what we are doing
Be the first to get latest updates and exclusive content straight to your email inbox.
We promise not to spam you. You can unsubscribe at any time.
Invalid email address