A 404 error page, or for those not familiar with the term, the 'Page not Found error' is important to have with any website. At Blondish.net, there is an article that illustrates the importance of a custom 404 page in detail, but it is really simple.
1. You are keeping your visitor within the site and giving them an alternate way to find what they are looking for.
2. The search engines will not frown as much on your custom 404 page as you are being courteous to your user, and once again, giving them another way to find what they want on your site.
A lot of themes come with the 404.php file, but there are some that do not. In the case you are making your own theme, or if you have downloaded a freebie, then you can make your own.
1. You need to know where to get the code for the 404 page, which can easily be found in the WordPress Codex. In the case of this tutorial, it will be using the basic code.
Error 404 - Not Found
2. Sure, you have a 404 page that will say "Error 404 - Not Found", but you really need your site to do something. Perhaps you should add articles that are popular or want your readers to see that may be missed. Or perhaps it was a click on an old internal link from an old blog entry, you should think about putting a search form. A search form will really help.
3. Edit your message to something friendly. Sometimes "Error 404 - Not Found" might be a bit shocking and make your user think they did something wrong. You could direct them to the home page of the site or as already suggested, articles you want your visitors to read.
Here is an example that is used at Blondish.net
Oopsie! Sorry for the inconvenience.
If you were looking for something on Blondish.net, and did not find it you can contact me or use the form below to search for it. Again, apologies!
The message is allowed to be used. Just change the site name. No credit back is needed.
4. Add your recent posts. This may entice your readers to stay on the site. It is also fresh content and easier than adding featured posts (and editing them from time to time.)
Recent Posts
5. Get the search engines to find the custom 404 page. In your .htaccess file, you need to put the code:
ErrorDocument 404 /index.php?error=404
In the case your installation is not on the root of your site, but instead a subfolder, you need to make sure the folder name is added before the index.php link for the .htaccess Error Document function.
Very short and simple, right?

March 12th, 2009 at 1:41 am
I have been thinking of “dressing” up my 404 page..thanks for the tips.. seems good sense to link it to your recent posts.