BuycPanel Blog

BuycPanel Blog

Latest news and updates

Custom Error Pages Using cPanel

Posted by Jamison on 05 10 2015.

No matter how well planned your website is, you are bound to have to change, replace or relocate some pages within your online site. These pages will be replaced by the infamous 404 Error Pages, a common eyesore for many web users. As a site owner, you have the choice to leave this page be or use it to your advantage.

 

Error pages receive a considerable amount of traffic. Are you sure you want that going to waste?

 

You have choices available to you. Custom error pages are a thing, and you should take advantage of it!

 

Find out why they got there. 

 

Error pages are known to drive users away- however, this shouldn’t be the case for your site. If the error page to catches their attention, you can flip the situation to your gain. Instead of using the generic 404 error page or the ‘page is not found’ notice, a good…

No matter how well planned your website is, you are bound to have to change, replace or relocate some pages within your online site. These pages will be replaced by the infamous 404 Error Pages, a common eyesore for many web users. As a site owner, you have the choice to leave this page be or use it to your advantage.

 

Error pages receive a considerable amount of traffic. Are you sure you want that going to waste?

 

You have choices available to you. Custom error pages are a thing, and you should take advantage of it!

 

Find out why they got there.

 

Error pages are known to drive users away- however, this shouldn’t be the case for your site. If the error page to catches their attention, you can flip the situation to your gain. Instead of using the generic 404 error page or the ‘page is not found’ notice, a good website owner will use this opportunity to explain what got the user to that page in the first place. Put an explanation in place and offer options for getting to the user’s original intended page.

 

Here are other things you should consider in building your custom error page:

 

  1. Make sure the design blends well with the whole site. Customizing your error page is now possible, and you can now go beyond the bland 404 pages of the past.
  2. Offer complete information to your visitors. Give them directions going to the page they intended to reach. Place links to the new locations or a home page link for easier navigation.
  3. Make it light. Use humor and creativity to help ease the user’s frustration. Not getting to where they want to be in a place that’s supposed to be convenient like the internet is very frustrating. Through emoticons or clever wordplay, you can prevent the user from backing off quick.
  4. A report button and a search field. Give them the option to report the error. This makes them feel they are part of the solution and that you have given them the chance to air their grievance. The search field gives them a way to move forward.

 

To make custom pages in cPanel, follow these steps.

 

  1. Go to cPanel → Advanced → Error Pages
  2. Choose the error page number.

 

Error pages can be one of the following types:

  • 400 (Bad Request)
  • 401 (Authorization required)
  • 403 (Forbidden)
  • 404 (Wrong page)
  • 500 (Internal server error)

 

  1. Create a .htcaccess file inside the public_html directory of your chosen error page

Remember:

For custom 404 error pages, include this inside the .htcaccess file:

ErrorDocument 404 /404.shtml

For custom 505 error pages, include this inside the .htcaccess file:

ErrorDocument 500 /500.shtml

 

When creating the file, the cPanel interface allows you to add the following:

 

  • Referring URL – Link that goes back to the page prior to the error.
  • Visitor’s IP Address – Displays the user’s IP address.
  • Requested URL – Shows the URL the user intended to view.
  • Server name – Shows your site’s server name.
  • Visitor’s browser – Displays the user’s browser (e.g. Google Chrome, Safari, etc.)

 

  1. Click ‘Save’ and now your custom page is ready.

 

When you treat the error pages with the same precision you do with your intended content, you can use this seemingly dismal situation to your advantage. Have fun with it and reap the benefits of this smart trick many website owners overlook.