Pages other than my homepage do not load and instead show a 404 error Print

  • 0

Problem Description

  • When you visit your homepage, the site loads correctly
  • When you visit any page of your website that isn't the homepage, the browser shows a 404 error - page or file not found.

Problem Resolution

This means that your content management system, like WordPress, is using SEO friendly links / permalinks, but the necessary configuration file to make them work is missing! This is the .htaccess file.

To resolve this, follow these steps:

  1. Follow our guide to using the Plesk File Manager to learn how to access the file manager, find your web root folder (ex: where WordPress resides), and create a new file
  2. Create a file called .htaccess (don't forget that leading dot!) The file must be created within your web root -- For example, with WordPress this is the same folder that contains the wp-config.php file
  3. Within the file, copy and paste the default .htaccess code for your web app. For example with WordPress you can obtain that code from the WordPress documentation here. If you are not using WordPress, most content management systems publish their .htaccess file defaults in their documentation, however if you can't find it there, you can always download a fresh copy of the CMS from their website and grab the .htaccess file contents from there.

That's it! Try navigating to the non-homepage pages of your site now.

Troubleshooting

Permalink Corruption: If you're using WordPress and that hasn't resolved the problem, try logging in to the WordPress admin, navigate to Settings > Permalinks. At the bottom of this page click save, then repeat the steps one more time.

Random Plesk Default Page: If you've recently added your domain to Plesk and you've tried all of the above and are still experiencing a 404 that randomly occurs on any pages of your site (including the homepage and even in the WordPress admin), this may be due to a longstanding, but very rare web server issue we've been tracking. It occurs roughly once every few months. As of Jul 2021 this hasn't yet been permanently resolved, though we have a good workaround. To have this resolved, please open a ticket indicating that you've completed all the steps in this guide and that you believe the issue to be the 'nginx random plesk default page' issue and we'll fix it up for you. Be absolutely sure that you truly have completed all steps in this guide before you do this -- if we find one of the above solutions *does* solve the problem and it wasn't this issue a fee may be associated with the repair for those without a Hands-On Support subscription.


Was this answer helpful?

← Back