How To Redirect 404 Error Page To Homepage in Blogger

Hello Everyone, Today in This Post I am Going To Share a Script Which Will redirect the users of your website to homepage automatically, you don’t need to add redirect for each link, just you put a script and it If the rest works, then read this post completely, so that you do not face any problem while installing the script.

There is no denying that it is actually quite difficult to fix broken links on a blog. There can be many different reasons for this like the negligence of the blog admin. Who misplaces or writes the link in an article.

Or it could also be due to search engine crawling which mis-translates the URL of the article on the blog.

This error URL can be customized in a special way. That is, it can be directed to the home page of the blog or to a specific page.

How To Redirect 404 Error Page To Homepage in Blogger :-

Step 1 :- First Go To Blogger.Com.
Step 2 :- Then Login Your Account.
Step 3 :- Then Click on Theme Menu.
Step 4 :- After Click on Edit Html.
Step 5 :- Then Paste The Given JavaScript Code Above The </body> Tag.
<b:if cond='data:view.isError'>
window.location.href = &quot;<data:blog.homepageUrl/>&quot;;
Step 6 :- Then Don’t Forget To Click on Save Theme.

Note :-
If you want to redirect somewhere else or don’t want to redirect properly, then use below code.

<b:if cond='data:view.isError'>
window.location.href = "";

Conclusion :-

It is quite difficult to find and fix all the broken links so in that case the above code will be useful for you, if you face any problem in installing the code please leave your comment below.

In this post I have explained How To Redirect 404 Error Page To Homepage in Blogger. I Hope this tutorial can be useful for you. Thank You for Visiting Our Website.

Refrence :


Leave a Reply

Your email address will not be published. Required fields are marked *