When a website visitor try to find or visit a URL which is no more available on your website, your web server returns a 404 (Page Not Found) error. This error is read by the browser and displayed to the end user. This error may arise due to broken links or mistyped a URL by the end user or a recent update with some modification of some or all permalinks of website. The generic 404 (Page Not Found) error as displayed to the end user is very boring and frustrating. The end user may get disappointed and will try to look the same information/product from some other website or even from your competitor. It is always advisable to have a custom 404 page where you can write your own user friendly message or link to you main site. If you do not want to lose your website visitors Google is there to help you to make a custom 404 page which is very friendly to your site visitors. What Google widget will do for you?
- It adds a search box for your site with appropriate search suggestions.
- It tries to provide alternatives to incorrect URLs.
What you need to do is just copy and paste the code given below to the 404 error page at your web server or add this code to your 404.php page shipped with your WordPress theme. Here is the code. You need to change techrecorder.com to yoursite.com
You can add this code to your WordPress blog by following these steps
1. Open your WordPress admin panel:
2. Choose Appearance menu.
3. Choose the Theme Editor page.
4. Check to see if your theme includes a ’404 Template’ in the list of files.
5. Click the link for ’404 Template’ along the right side of the page.
6. Edit the message text to and put the Google Widget code there.
7. Save your changes
Now you are done. This addition of Google Search Widget to your custom 404 page will makes it easier for users to find the information they need.