How to Fix 'HTTP 500 - Internal Server Error' Print

  • 500 Error, Internal Server Error, HTTP Error, Server Error
  • 301

What can cause the ‘HTTP Error 500 – Internal Server Error’?

The ‘HTTP Error 500 – Internal Server Error’ can be caused by any of the following:

  • WordPress plugin or theme functions
  • Corrupt .htaccess file
  • Hosting a large file on your website

How to fix the ‘HTTP Error 500 – Internal Server Error’?

This error can be fixed in the following ways

1) Disable plugins

Missing or broken plugins are often the cause of the Error 500. When trying to fix this error, your first step should be to disable any plugins you have recently installed or updated, clear the cache and then see if that resolves the error.

You can disable the plugins by logging into your WordPress admin dashboard > Plugins > Deactivate.

If you're unable to access your WordPress admin dashboard, you should access your WordPress hosting dashboard and then go into File Manager >> WP Content >> Plugins folder and then rename the relevant plugin folder. That should deactivate the plugin straightaway.

To troubleshoot the problem, you may also need to update any outdated plugins, and in case of a missing plugin delete its plugin folder and then re-install and activate it.

To be on safe side, make a backup of your WordPress files and database from your hosting dashboard >> Security >> Backups.

2) Re-create .htaccess file

.htaccess file is the gatekeeper of your web server and any misconfigurations in it can cause the Error 500. You can easily re-create the .htaccess file to remove the misconfigured rules.

To re-create the .htaccess file:

  • Rename or delete the .htaccess file by logging into hosting dashboard >> File Manager >> root directory (public_html)

  • Right click on the .htaccess file, click Rename and then hit Confirm. Then reload your website to see if that resolved the issue.

  • Create a new .htaccess file with the correct configuration, login to your WordPress dashboard >> Settings > Permalinks > hit Save without making any changes. This will create a new .htaccess file automatically with the proper rewrite rules. Then reload your website to see if that resolved the issue.

3) Incorrect File & Folder Permissions

If the issue persist you should check if the file and folder permissions for your website are set properly. You can re-set the permissions from hosting dashboard >> WordPress >> Install & Manage >> Reset Permission

4) Check Server Logs

Server logs can also provide valuable information on what's causing the 500 Server Error. To check what's going on you can dive into the server error logs by going to hosting dashboard >> Stats > Error Log. You will see the all the errors with date/time stamps along with the description of the error, folder or file causing the error.

WordPress 500 Error Server Logs

Example errors that can cause a 500 Server Error:

[Tue APR 19 12:34:16.770700 2021] (13)Permission denied: [client 87.0.X.X] 
/home/user/public_html/.htaccess unable to check htaccess file, ensure it is readable

This error is mostly caused by incorrect permissions of the .htaccess file or the folder it is inside of (In this instance one can see it is the public_html folder). To fix this error, you can check that .htaccess file has 644 permissions and your directories have 755 permissions. To modify the files/folders permissions use SSH, FTP, or your File Manager.

[Mon Apr 29 10:34:16.770700 2021] [client 17.0.X.X] /home/user/public_html/.htaccess:
 Invalid command, perhaps misspelled or defined by a module not included in the server
 configuration

This error points to "incorrect directives inside the .htaccess file." To fix it, you should revert any recent changes made to .htaccess, as those are most likely found to be causing this error.

[Tue Apr 30 05:22:08. 2022] [core:error] [pid 23000] [client 91.X.X] 
End of script output before headers: filename

This error occurs when the permissions of a file are too wide. In this instance, filename is the name of the file in question. To fix this issue, try changing the permissions of that file to 644 (the right permissions for all your website files)

5) Very large files on your site

Having a large file on your website can also cause the 500 Server Error. On most of Rocket Domains hosting accounts, we have a size limit for files that can be accessed through the web which is 8GB. If your website has a file larger than that limit, you will see the 500 Server Error.

To fix this issue, have a look at your website’s files either via SSH, FTP, or File Manager and locate the one causing the problem.

You may also find logs with PHP errors showing the problem location. A log file is automatically created when your website’s PHP scripts encounter any non-critical errors or warnings during their execution. That log file’s name is "php_errorlog" and it can be found in the same directory as the script that caused the errors. Normally, this would be your website’s directory.


Was this answer helpful?

« Back