SEO Anti-patterns: 301 redirect all your 404s to your homepage
Sometimes I encounter new “SEO hacks” that people apply, that are actually anti-patterns. One of these new anti-patterns I noticed is the pattern of 301 redirecting all your 404 pages to your homepage. Let me explain why this is a lot like cleaning up your room by throwing everything into a drawer and what the better solution would be.
The premise of this SEO hack
The premise of this hack is that 404 errors are counted by Google, and that through some magic the number of errors on your site affects your site’s overall ability to rank. The solution, that really isn’t a solution, that people come up with is then to start 301 redirecting all error pages to their homepage. Let me quote some of the reasons people give for doing this:
to siphon Google Page Rank (TM) from missing pages to the homepage
If you care about your website, you should take steps to avoid 404 errors as it affects your SEO badly.
I have a website, every time I login to Google webmaster tools, I found many new discovered 404 error links, the problem is not in 404 errors itself, but when Google see them and count them for you!
Let’s be clear: we’ll be the first to tell you that you should keep an eye on your 404 errors and try to fix them where possible. Google indeed shows a graph of your 404 errors in Google Search Console and lowering the number of 404s on your site is often a good idea. That doesn’t mean that your site shouldn’t have any 404s.
Let me go back to my analogy of throwing everything into your drawer when your dad or mom told you to clean up your room. Everything, in this case, means not just the dirty clothes, or your toys, but also that half-emptied soda bottle, that half-finished bag of snacks, etc. You know what that makes your drawer when you clean up your room like that? A mess. And soon your whole room will start to stink because you cleaned up like that. This situation is no different.
I verified this with Google before I wrote this article, see John Mueller’s response:
As John explains: when you do this blanket redirect, all those URLs are treated as 404s. So none of them spread value. So the premises listed above are all wrong. On top of that, by 301 redirecting all your 404 pages, you throw away the opportunity to find real errors on your site and fix them.
Better solution to 404s
The better solution for this problem of having too many 404s is much more granular. You see, 404 redirects can exist for lots of reasons, and each of those reasons has their own “solution”. For instance:
- Someone linked to an article and made a mistake in their URL. If you can redirect that wrong URL to the right article: do so.
- You’ve deleted a page, you should think about that and act properly, we have an article on that.
- Someone is trying whether your site can be hacked through a certain URL, that 404 is 100% the right thing to serve.
- You have a lot of 404s on your site because you had a broken link in your template somewhere (all too common): fix that broken link. Then redirect all those 404s to the right page.
- Someone is typing in random URLs on your site just to see if something exist: a 404 is right. Of course, then your 404 page could be helpful in guiding them to the right spot.
How common is this hack?
Unfortunately, all too common. I encountered at least 3 plugins with major user bases on WordPress.org that do this, and only this:
Together they account for 240,000+ sites that show this behavior and there are probably a lot more.
Stop 301 redirecting all your 404 pages
Now, don’t take this as though we’re telling you not to 301 redirect 404 errors. We’re telling you to do it granularly. There’s nothing wrong with having a few 404 errors on your site, and you should definitely keep an eye on them. The redirect manager in Yoast SEO Premium can make this really easy to do.
Coming up next!
-
Event
Wordcamp Asia 2025
February 20 - 22, 2025 Team Yoast is at Attending, Sponsoring, Yoast Booth Wordcamp Asia 2025! Click through to see who will be there, what we will do, and more! See where you can find us next » -
SEO webinar
Webinar: How to start with SEO (December 18, 2024)
18 December 2024 Learn how to start your SEO journey the right way with our free webinar. Get practical tips and answers to all your questions in the live Q&A! All Yoast SEO webinars »
A really useful article, thank you Joost. I’ve been wondering how to deal with this as I’ve manage multiple websites and have been putting the issue to one side.
Must do: update my current 404 page & regularly check console for errors. Just a case of doing it isn’t it? ;) Thanks for the reminder.
Hi there wоuld you mind stating which blog platform you’re uѕing?
I’m looking to start my own blog soon but I’m having a hard time making a
decisіon between BlogEngine/Ꮃordpress/B2evolution and Ꭰrupal.
The rеason I asқ is because your design and style
seems different then most blogs and I’m looking for something completeⅼy unique.
Ꮲ.s Sorry for being off-topic Ьut I had to ask!
Thanks Gorden! We’re on WordPress :-)
good insight, am going to have a review on these 404 redirects on my page
I’m still confused.
Example, I have a Real Estate website with thousands of properties for sale. Every day hundreds of these properties are sold so I do not want them to appear on the Web. In such case it is more advisable:
1. Return a personalized 404 page with other related properties.
2. For each property sold / deleted redirect 301 to an existing Landing Page with related properties.
I maintain websites for several realtors and I have the exact same issue. I’d be very interested in any sugestions/solutions for this problem.
Hi Jose and Larry, We wrote an article on that (optimizing real estate websites). Below the heading “The ever changing content of your real estate site” you’ll find how to deal with sold properties best! https://yoast.com/optimize-real-estate-site/
Hi,
Thanks for sharing such a knowledgeable information. I am SEO executive. I’ll definitely try this methods.
It’s actually not a good idea to redirect all 404 rrors to homepage…
Sometimes all it takes is just a little fix
it would be a huge improvement if Yoast would warn me if there’s a link to a non-existing page. Even better: make a list of pages where this happens.
Hi Peter, If you have any suggestions for improvement, please add your idea on our GitHub repository: https://github.com/Yoast/wordpress-seo/issues Thanks a million!
Good article. In some cases, it may not be possible to steer visitors to the “right” page. I do like the suggestion of Chinonso to direct visitors to a well-structured ERROR PAGE which may help the visitor find what he is looking for.
No substitute for a proper redirect, but certainly better than the 301.
if there is a 404, try and fix them if they are still around, If not redirect to a relevant page if you have any. If not then give them a 410 header, no point google trying to crawl around old 404 pages wasting your crawl currency on something thats not there any more
I found this article enlightening and useful; redirecting to homepage may be annoying to site users/visitors, most especially if there are a great number of posts redirecting.
But for my money, it is better to redirect broken or unavailable URL to a well customized Error Page, at least this page will inform a user of the state of the page he/she is looking for.
I think the best feature to employ in solving this issue is redirecting every old URL to new URL which Yoast SEO Premium does.
I am looking forward to using Yoast SEO Premium for our website.
Great suggestion to set up a thoughtful Error page.
Yeah your error page should be good, I linked to an article that talks about that within the article as well.
This article has helped me a lot, Thank you for sharing
This was quite an interesting read and I totally get your point, plus I agree with you.
The problem is that 404 to 301 redirects is very simple to do and with a simple one-time edit, you don’t need to go over ad over checking those 4040 pages.
Since it’s our nature to always look for something easier, that’s what most of us do.
However, I believed redirecting a 404 URL to the new URL is the best practice. In fact, 404 to homepage can really confuse users.
Thanks!
Very good article. I just do not understand what you mean by the solution of item 4: Then redirect all those 404s to the right page.
Redirect to which page?
OBS: Excuse my English is not good, so I should not have understood.
The right page is the page that the content is replaced by. If there is no such page, set it to a 410.
What if I did this in 2012? I had to clean up my site after Penguin problem – Google took action against my site. So I know I did a lot of redirecting 404s to my home page. Should I try to go back now 6+ years after the fact and “fix” those redirects?
Thanks!