How to Fix the 404 Not Found Error in cPanel
Seeing a "404 Not Found" error on your website can be alarming, but it simply means your web browser reached the server, but the server couldn't find the specific page requested. This is rarely a permanent issue. Here are the three most common ways to resolve a 404 error directly from your SastoHost cPanel.
Solution 1: Regenerate or Fix the .htaccess File
If you are using WordPress or a similar CMS, a corrupted or missing `.htaccess` routing file is the culprit 90% of the time. Resetting it usually fixes the problem instantly.
- Log in to your cPanel and open the File Manager.
- Click the Settings button in the top right corner, check the box for Show Hidden Files (dotfiles), and click Save.
- Navigate to your public_html folder (or the root folder of your specific domain).
- Locate the .htaccess file. Right-click it and select Rename to change it to something like .htaccess_old (this acts as a backup).
- If you use WordPress, log into your WP Admin dashboard, go to Settings > Permalinks, and simply click Save Changes without editing anything. This forces WordPress to generate a brand new, clean .htaccess file.
Solution 2: Correct Incorrect File or Folder Permissions
For security reasons, web servers are strict about who can read files. If a file's permissions are set incorrectly, the server will block access and throw an error.
- Inside the cPanel File Manager, navigate to the file or folder that is causing the 404 error.
- Look at the far right column labeled Permissions.
- Standard web folders should always have permissions set to 755.
- Standard web files (like .php or .html documents) should always be set to 644.
- If the numbers are wrong, right-click the item, select Change Permissions, update the numbers to match the rules above, and save.
Solution 3: Verify the File Actually Exists
Sometimes the simplest answer is the correct one. The file might have been accidentally deleted, moved, or renamed.
- Check for Typos: Ensure the URL typed into the browser exactly matches the file name. Remember that Linux servers are case-sensitive (About.html is entirely different from about.html).
- Check the Directory: Ensure you uploaded the files into the public_html folder, not just the home directory of your hosting account.
- Check the Default Index: If your main homepage is throwing a 404, verify that your primary homepage file is correctly named index.php or index.html.
Tried these steps but still seeing a missing page error? Don't worry! Open a support ticket and our SastoHost technical team will investigate the server logs to fix it for you.
