...Create Custom Error Pages

Any issues with adjusting your .htaccess file fall under our Best Effort support policy. Best Effort does not include content management, coding or designing for your websites. We may also direct you to a better resource for your issue, such as Plugin Developer, Designer, Software Author etc. Best Effort is not covered under the same SLA's as our supported services and does not guarantee any future support for any issue. Please understand that Best Effort issues may take longer to resolve.

Error pages are a part of any website. No matter what, website visitors will sometimes encounter error pages. If you use custom error pages, however, you can turn an error page into a positive user experience. This tutorial will show you how to add custom error pages to your websites.

Before you set up your error pages, you'll need to create your error pages. You can do this, however, you'd like: hand coding your page, using a site builder or another way. When you're done building your error page, save the file so it can be uploaded to your server.

Now to set up custom error pages, you will edit your website's .htaccess file. Before editing your .htaccess file, make sure you're also familiar with SFTP.

  1. Before editing your .htaccess file, upload your customized error pages to your server. You can do this via SFTP. Put these files in the content directory for your website.
  2. Log into your server via SFTP using the FTP program of your choice.
  3. Download the .htaccess file that corresponds to the domain where you want to use custom error pages.
  4. Open this file in a text editor and add this information:
    # serve custom error pages 
    ErrorDocument 400 /errors/400.html
  5. Replace /errors/400.html with the file path to an error page you have uploaded. This example has "400," for a 400 error.
  6. Add as many lines as needed, changing the error number and the file path as needed.
    ErrorDocument 500
    ErrorDocument 404 ETC...
  7. When you're done adding to your .htaccess file, save and exit the file. Then upload it back to the directory you got it from.
  8. Finally, test your website to make sure your error pages are functioning.
Have more questions? Submit a request
Powered by Zendesk