The Internal Server Error, sometimes known as 500 Internal Server Error, is a generic message that you see when something goes wrong with your web server. This makes it a little hard to diagnose (because it just means “something” went wrong). But here are some of the most common ways to fix it:
How To Fix Internal Server Error On WordPress
- Force WordPress to generate a new .htaccess file. To do this, rename your current .htaccess file to .htaccess_old via FTP. Then, head to Settings → Permalinks in your WordPress dashboard and just click the Save button to make WordPress generate a new .htaccess file.
- Deactivate all of your plugins. Then, reactivate them one-by-one to find the culprit. If you can’t access your WordPress dashboard to deactivate plugins, you can deactivate your plugins via FTP by renaming the wp-content/plugins folder.
- Increase PHP memory limit. To do this, add the following code snippet to your wp-config.php file via FTP:
- Reupload your wp-admin and wp-includes folders. Download a fresh copy of WordPress from WordPress.org. Then, upload just the wp-admin and wp-includes folders to your server. Make sure to overwrite files when you upload them.
Enabling WordPress debugging mode allows you to write all errors to a file called debug.log that is stored inside the wp-content folder.
To enable debugging:
- Login to your WordPress directory via FTP and download the wp-config.php file
- Open wp-config.php file and add the following code just before the line that says
/* That's it, stop editing! Happy blogging */:
define ('WP_DEBUG', true); define ('WP_DEBUG_LOG', true); define ('WP_DEBUG_DISPLAY'. false); @ini_set ('display_errors', 0);
- Save your changes and upload wp-config.php to your WordPress directory overwriting the older version
Now, reload your site to trigger the error. Open your WordPress directory, navigate to the wp-content folder and open debug.log. If you have a developer friend, they can help you to decipher the errors.