They can also get the error 404 when they type your blog URL directly and probably mistype it.
In this tutorial I will be sharing with you how you can set a custom page not found or error 404 in blogger such that any of your blog users mistyping your blog URl will be redirected to your homepage automatically.
Let's get started:
How To Set Custom Page Not Found In Blogger
- Log in to your blogger dashboard
- Navigate to Settings > Search Preference > Custom Page Not Found.
- If you've never set up a custom page not found in your blog, the box will be blank as seen in the image above.
- Now, copy the code below, paste it in the box and save it.
Oops! The page you're looking for in this blog does not exist.Customization:
You will be redirected to the homepage shortly. If you are not redirected shortly <a href="http://www.yourhompage.com/">Click Here</a>
<script type = "text/javascript">
BSPNF_redirect = setTimeout(function() {
location.pathname= "/"
}, 5000);
</script>
Replace code in blue with your blog homepage URL. This for users landing on a non existing URL of your blog with a browser that has no java script enabled in it. So they can click manually and get redirected to the homepage.
That has been all about setting a custom page not found (error 404) in blogger, if you have any question regarding this article, please feel free to leave a comment for us.
No comments:
Post a Comment
We love to hear from you!
We encourage comments, but please DO NOT SPAM. We do pre-moderate some comments with links.
THANKS.