Skip to main content

How to Fix 404 Page Not Found Error and Redirect Page To Custom URL

More or less every blogger faced 404 error during their blogging carrier. If you are a Google webmaster user, you must aware this 404 error and how to fix this. The 404 error occurs due to broken links. Broken links refer to pages that no more exist on your blog. This may happen because you might have been deleted the post, changed the URLs over time or visitors misspelled the URL. Read also : Google Webmaster Tools - Complete Guide.

How To Find 404 Errors

To check 404 error for your blog you must have to use Webmaster tools. Google Webmaster tool is one of the best and free tool to analyze your blog. If you are an existing Google account holder you directly login to Google Webmaster tools with your existing Google account. Otherwise you need to create a Google account first.

After login to Google Webmaster tool, you need to add your blog to Google Webmaster tool and then very that you are the owner of the blog. There are four methods to very your blog. Follow any one method to very the blog. Blogger's use meta tag method to very their blog.

Read also : How to add your blog to Google Webmaster Tools.
                         How to submit blogger sitemap to search engines.

Once you very the blog, your blog will appear on the Google Webmaster. Once Google crawled all your blog data, click on your blog name or click view details in the Google Webmaster tool to analyze your site.

How To Fix 404 Error

Bloggers can fix this 404 error in two ways. One is redirecting all broken links to homepage and the other is redirect broken link to custom URL. Here I will discuss both the method so that you can fix 404 error according to your choice.

Redirect to Custom Page URL

It is one of the preferred method to fix 404 error for particular broken link. Using this method bloggers can fix each and every 404 error and fix it with the relevant post / page. Follow below steps to fix 404 error by redirecting to custom page URL.

Step 1. Go to Blogger dashboard and then click Settings and then click Search preferences.

Step 2. Under Errors and redirections, you will find two options namely Custom Page Not Found and Custom Redirects. Here you need to click Edit button of Custom Redirects. If you do not see From and To then click New redirect button. Now in the From box enter the deleted URL or the URL that gives 404 error and in the To box enter the correct URL where you want to redirect the page.
Remember, no need to enter the whole URL in the From and To box instead enter the URL excluding the domain name. After that click checkbox Permanent and then click Save changes.

LOOK AT THE BELOW EXAMPLE

I am showing you one example here. In my blog I had deleted one post accidentally. When I login to my Google Webmaster account, I found http://www.allbloggerbuzz.com/2013/08/HowToDownloadBloggerTemplate.html    links with 404 error. Now obviously, it is necessary to fix it immediately so that readers can land to their preferred post. Therefore, I need to fix this issue by redirecting this link to http://www.allbloggerbuzz.com/2013/08/how-to-download-blogger-template.html. To fix this issue in the From box, I just need to enter the   /2013/08/HowToDownloadBloggerTemplate.html     instead the whole link and in the To box I need to enter the  /2013/08/how-to-download-blogger-template.html    instead the whole link. Remember there must be a forward slash ( / ) at the beginning.


Redirect All Broken Links to Homepage

If you do not want to fix 404 error for all broken links one by one then it is better to redirect to the homepage of your blog. Follow below steps to fix 404 error by redirecting to homepage page.

Step 1. On the Blogger dashboard,  click Settings and then click Search preferences.

Step 2. Under Errors and redirections, click Edit button against Custom Page Not Found. Now you just need to enter the below text and code and then click Save changes.

Sorry, the page you're looking for in this blog does not exist. You will be redirected to the homepage shortly.
<script type = "text/javascript">
PNF_redirect = setTimeout(function() {
location.pathname= "/"
}, 3000);
</script>



According to you, you can modify the text which is going to be displayed for the broken links. If you wish to redirect the broken links rather than homepage then replace   pathname  with   href  and  " / "  with the url of the page. In the above code, the number 3000 is expressed delay time in milliseconds which can also be changed as you want.

That's it! Thanks for reading the post. Feel free to comment and share the post. Your one comment and share can appreciate me lot.



Recommended Post
Big on Hosting. Unlimited Space & Unlimited Bandwidth

Comments

Popular posts from this blog

How To Change Default File Download Path in UC Browser

All of us known that UC browser is the most popular, fast and less data consuming mobile browser for android devices. Many of us use UC browser on daily basis on our smart phones. By default UC browser has download path to internal memory device which is /storage/sdcard0/download. sdcard0 is the built in memory or internal memory of your device. Read also : How to fix HTTP and HTTPS Mixed Content Errors.

Do you know that this default download path can be changed? Since, internal memory is fixed, and once you exceed this value you can't download more. You need to move some data from mobile memory to the external memory which is sdcard1. If you change this default path to external memory card (sdcard1), you can download more data directly to your desired directory. Read also : How to Setup AdSense Page Level Ads and Fix Script Error.

Here, I will show you, how to change this default download path from internal memory card sdcard0 to external memory card sdcard1. To do so you need to…

How To Rename A WhatsApp Group

We all know that WhatsApp is the most popular messaging service for Android, BlackBerry, iPhone and for other platforms. In this post, I will show you how to rename an existing WhatsApp group. To rename an existing WhatsApp group your smartphone must have internet connection. After that you need to follow the below steps. Read also : How to track lost/stolen mobile phone and erase data remotely.


Step 1. Open WhatsApp application on your smartphone.

Step 2. After that you need to click CHATS tab and click on your group name.



Step 3. Once you click on your group name, you will able to see chat details. Now you need to click vertical dots located extremely top right corner and then click Group info. Read also : How to setup AdSense page level ads.


Step 4. Now you can easily rename your group. To rename the group just click Edit icon and then type the desired group name and click OK. Read also : How to protect your computer from WannaCry ransomware virus.


In this way you can rename a What…

Calculation of Total Marks, Percentage, Division, Remarks, Maximum & Minimum Number of Students in MS Excel

In this post, I will help you to learn how to calculate total marks, percentage, division, maximum number, minimum number and remarks of students of a class very fast. At first you need to look over the above image very carefully. The above image shows the marks obtained by six students of a class.

Formula to calculate Total Marks of all students within seconds 

First you need to find out the Total Mark of a single student who is on the top of the list i.e, Mani. To calculate Total Mark of Mani, click on the Total Mark cell address of Mani i.e, H6 and then type the formula =sum(1st subject's cell address i.e, b6:last subject's cell address i.e, g6) and then press Enter on the keyboard or click anywhere on the worksheet. Here b6 and g6 are cell address of 1st subject (English) and last subject (Biology) of that student. Read also : How to Enable HTTPS for Blogger Blog.

After getting results, click on the resultant cell address of Total Mark of the 1st student i.e., Mani an…

Change UC Browser Default Homepage in Android Phones

We all know that Android OS operated Smartphones and Tablets are great for web browsing. Like other browsers, uc browser has a default search engine Yahoo is set for web search. UC browser provides different kind of search facilities under 5 different categories namely Web, Video, Shop, Image and APP. Read also : How to protect your computer from WannaCry ransomware virus.

In this post, I will show you how to change the default search engines of uc browser in Android devices for their 5 different categories. To do so you just need to follow the below steps. Read also : How to Enable HTTPS for Blogger Blog.

Change Default Homepage for UC Web search

Step 1. At first you need to open UC browser
Step 2. After that click Search. Follow the below image.


Step 3. Once you click Search, you will able to see the default search engine's icon for Web search like y for Yahoo, g for Google. Now you need to click that search icon. Follow the below image. Read also : How to change UC browser defaul…

Enable Auto Save Forms & Passwords in UC Browser

Many of you use UC browser on daily basis on your smart phone but very less enable this feature. Enabling auto save forms and passwords allows the browser to remember the username and passwords. It gives you relief from entering username & password every time whenever you login to your email. Did you enable auto saving form & password? If not, then do it now. Read also : How to track lost/stolen mobile phone and erase data remotely.

In this post, I will show you how to enable auto save forms & password in UC browser in your Android phones. To do so you need to follow the below steps.

Steps to enable auto save forms and passwords

Step 1. At first open UC browser

Step 2. In the second step, tap on the horizontal bar.


On the next image, you will able to see Bookmarks, History, Refresh etc. icons. Now swipe this menu screen to the left and tap Settings. Read also : How to create custom AdSense Search Engine and make money from it.


Step 3.  Now on the Browser Settings, you w…

Best Video Calling App For 2G, 3G, 4G and Wi-Fi Network

More or less every mobile subscriber wishes to chat with their contacts by seeing his/her infront of them. Now a days video calling becomes more popular in urban areas rather than rural areas. After the invention of 3G network it becomes a trend to chat with loved one through video calling. Read also : How to protect your computer from WannaCry ransomware virus.

But what happened if you have 2G network instead of 3G or 4G. Could you be able to chat with your loved one by seeing him on 2G network? There is a good news for those who wishes to see their friends or family members on mobile screen when they talk to them. There are many application software available on internet which provides video calling facility even on 2G network. Read also : How to Setup AdSense Page Level Ads and Fix Script Error.

Although there are many video calling applications are available, among them my recommendation is IMO. Because IMO provides fast, free and high quality video calling facility to its members…

Change SMS Storage Location in Android Device

By default all the SMS that you have got from friends and mobile operators are stored in either SIM card or phone memory. There is a limited space in the SIM card to store your SMS. If the limitation exceeds all SMS you have got is start storing in phone memory. In this post I will discuss how to change default SMS storage location from Phone memory to SIM card in Android devices. To change the SMS storage location, you just need to perform the below steps.

Step 1. At first you need to open the Messaging application from the app screen. After that, you need to touch the Menu icon i.e., the three vertical dots of top right corner and then need to touch Settings.


Step 2. SMS Settings screen opens. Here, you need to touch Text Message(SMS).


Step 3. Now you need to touch SMS Storage Location. If you use dual SIM card on your Android device then you just need to select the desired mobile operator for which you want to change the SMS storage location either from Phone memory to SIM or SIM …