How to Create Custom Error Pages (404 and More) in cPanel

When a visitor hits a missing page, the server shows a plain "404 Not Found" message that looks nothing like your website. A custom error page keeps your branding and helps people find their way back. This guide shows you how to create a custom 404 page and other error pages for your Instant Access Internet Services website with cPanel's Error Pages tool, and how to use your own HTML page instead.

Which error pages matter?

CodeNameWhen visitors see it
404Not FoundThe page doesn't exist - a broken link or mistyped address. This is the one worth customising.
403ForbiddenAccess to a file or folder isn't allowed.
401UnauthorizedSomeone cancelled or failed a password prompt (see How to Password-Protect a Folder with cPanel Directory Privacy).
500Internal Server ErrorSomething went wrong on the server, often a script or .htaccess error.

Using WordPress? Read this first

WordPress handles its own "page not found" errors, so a 404 page made in cPanel won't appear on a WordPress site. Instead, edit your theme's 404 template or use your theme's or page builder's 404 page setting. The cPanel error pages still apply to non-WordPress folders and to errors that happen before WordPress loads.

How to create a custom error page in cPanel

  1. In cPanel, go to Advanced > Error Pages.
  2. If you have subdomains, choose the right one from the Managing menu. Otherwise your main domain is already selected.
  3. Click the error code you want to customise, for example 404 (Not Found). If it isn't in the list, click the Show All HTTP Error Status Codes tab first.
  4. Type your page content in the editor. You can use plain text or HTML - for example a heading, a short apology, a link back to your home page and your contact details.
  5. Optionally, click the buttons above the editor to insert details about the visit, such as the requested address or the visitor's IP address. These are added as special tags that the server fills in.
  6. Click Save.

Test it by visiting a page that doesn't exist, such as https://example.com/this-page-does-not-exist.

A simple 404 page example

<h1>Sorry, we can't find that page</h1>
<p>The page you're looking for may have moved or no longer exists.</p>
<p><a href="/">Go to our home page</a> or <a href="/contact">contact us</a>.</p>

To match your site's design, copy the HTML of one of your existing pages, replace the main content with your error message, and paste the whole thing into the editor.

Where the error pages are stored

cPanel saves each page in the domain's document root with a name like 404.shtml. You can open and edit these files later in File Manager (see How to Edit a File in cPanel File Manager). Deleting the file sends visitors back to the server's default error page.

Alternative: use your own page with .htaccess

If you already have a designed page, such as notfound.html, you can point the server at it with one line in public_html/.htaccess:

ErrorDocument 404 /notfound.html

Use a path starting with / rather than a full https:// address - a full address makes the server send a redirect instead of a proper 404 status, which search engines treat as a normal page. See How to Show Hidden Files (.htaccess) in cPanel File Manager to find .htaccess.

Troubleshooting

My custom 404 page isn't showing

Check that you edited the page for the right domain or subdomain in the Managing menu. Then clear your browser cache. On WordPress, see the note above. If an ErrorDocument line in .htaccess points to a different page, that line wins.

My 500 error page doesn't show when the site breaks

Many 500 errors happen inside PHP or in a broken .htaccess file, before a custom page can load. Fix the underlying error instead - your error log will show what's wrong (see How to Check Your Website Error Log and Recent Visitors and How to Fix the WordPress White Screen and 500 Errors).

Images and styles are missing on my error page

Error pages can appear at any address on your site, so relative links like images/logo.png break. Use paths that start with /, such as /images/logo.png.

Should I redirect all 404s to my home page?

It's better not to. Search engines treat that as a "soft 404". Show a helpful 404 page, and set up 301 redirects only for specific old pages that moved - see How to Set Up a 301 Redirect in cPanel.

Related guides

Still stuck? Open a support ticket and the Instant Access Internet Services team will help.

Ultrafast LiteSpeed hosting from InstantAccess.net: free SSL, free backups, cPanel included, no contracts. Check out our $10/month hosting.
  • custom 404 page cpanel, cpanel error pages, create 404 page, custom error page htaccess, errordocument 404, 403 error page
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

How to Show Hidden Files (.htaccess) in cPanel File Manager

If you are looking for your .htaccess file and it isn't there, it's almost certainly just hidden....

How to Use cPanel File Manager to Manage Your Website Files

cPanel File Manager lets you work with your website files right in your web browser -- no FTP...

How to Edit a File in cPanel File Manager

Instant Access Internet Services customers can edit a file in cPanel File Manager right in the...

How to Upload and Extract a ZIP File in cPanel

The fastest way to put a whole website or a folder full of files on yInstant Access Internet...

How to Compress and Download a Folder in cPanel

cPanel File Manager can download single files, but not whole folders. The trick is to compress...