1. Knowledge Base
  2. >
  3. Results
  4. >
  5. How to Fix the Internal Server Error in WordPress

How to Fix the Internal Server Error in WordPress

The 500 Internal Server error is not always due to WordPress. It can be caused by other issues on the server as well. This article addresses the common causes of the 500 Internal Server errors associated with WordPress.

Before making any of the following changes to your website, it is suggested that you backup your website so that you can revert to a previous version if something goes wrong.

Corrupted .htaccess File

To address the issue with a corrupted .htaccess file, you can try creating a new .htaccess file. Here are the instructions on how to address this issue.

From cPanel:

  1. Log in to cPanel.
  2. Look for the Files section, click on the File Manager icon.

    cPanel - File Manager

  3. Click on the Settings box on the upper-right side. 

    cPanel - File Manager Settings

  4. Check the box for Document Root and select the domain name you wish to access from the dropdown menu.

    cPanel Document Root

  5. Make sure Show Hidden Files (dotfiles) is checked.

    cPanel show hidden files

  6. Click Save. The File Manager will open in a new tab or window.
  7. Look for the .htaccess file in the list of files. You may need to scroll to find it.
  8. Right-click on the .htaccess file, then select Rename. Rename the file as .htaccess.bak. Alternatively, you can click on the icon for the .htaccess file, then click on the Rename icon at the top of the page.

    Rename .htaccess File

From the left-hand navigation menu of the WordPress Dashboard:

  1. Navigate to Settings, then click on Permalinks.

    Wordpress Permalink

  2. Review the settings to be sure they are set up properly.

    Permalinks Settings

  3. Click the Save Settings button.
  4. Try reloading the site to see if the 500 Internal Server error has been resolved.


Still Getting a 500 Internal Server Error?

Increase PHP Memory Limit

If the error persists, try Increasing the PHP memory limit. Please refer to this article for more information on resolving the PHP Memory Limit Error.


Deactivate/Reactivate All Plugins

If increasing the PHP memory limit does not resolve the 500 Internal Server error, it may be caused by one or more plugins installed on WordPress.  Oftentimes, if a new theme is installed, a previously installed plugin will not be compatible and will result in the 500 Internal Server error.

From cPanel:

  1. Log into cPanel.
  2. In the Files section, click on the File Manager icon.

    cPanel - File Manager

  3. Select Web Root (public_html/www) and the Document Root for the domain using the WordPress install, then click save.

    cPanel settings

  4. Click to expand the public_html folder, then navigate to the /wp-content folder.

  5. Right-click on the /wp-content/plugins folder, then rename it as plugins.old. This will deactivate all plugins and will also lock the WordPress admin area in most cases. You will still be able to perform these steps from within the File Manager.

    Renaming Plugin

  6. Reactivate the plugins folder by following the above instructions and renaming the folder back to plugins. This will allow you to reactivate each plugin individually to isolate the offending plugin and resolve the 500 Internal Server Error. This should also allow access to the WordPress Dashboard again.

From the WordPress Dashboard:

  1. Reactivate each plugin (one at a time) and refresh the website to see if the issue has been resolved.

    WordPress reactivate plugin

    The 500 Internal Server error is not always due to WordPress. It can be caused by other issues on the server as well. This article addresses the common causes of the 500 Internal Server errors associated with WordPress.

    Before making any of the following changes to your website, it is suggested that you backup your website so that you can revert to a previous version if something goes wrong.
Need additional assistance? HostGator's Support is here to help. Please contact us via phone or Live Chat so we can assist!