Quick answer
A 500 error (Internal Server Error) means the server failed to process the request due to a configuration, code, or permission error. The fastest fix is to check the error log, disable recently added plugins, and restore a backup if needed.
How to recognize the problem
- The page shows a white background with the text "500 Internal Server Error"
- The site opens intermittently, but sometimes throws a 500 error
- The error appears only on certain pages or after login
- The site admin (e.g., /wp-admin) also shows a 500 error
- After modifying the .htaccess file, the site stops working
Most common causes
Error in the .htaccess file
An incorrectly entered rule or an incompatible plugin can cause a 500 error. This is a common cause after manual changes or site migration.
Faulty PHP code or insufficient memory
A plugin or theme with a code error, or too little PHP memory, leads to execution interruption and a 500 error.
Incorrect file and folder permissions
If files have incorrect permissions (e.g., 777 instead of 644), the server may deny access and show a 500 error.
Mismatched PHP and plugin versions
After upgrading to a newer PHP version, old plugins may stop working and cause a 500 error.
Server overload
Temporary issues on the hosting server (too many requests, database crash) can lead to a 500 error.
Step-by-step fix
- 1
Check the hosting panel error log
Log in to your hosting panel (e.g., cPanel or Plesk) and find
Error Log. The latest entries will show the exact cause, e.g.,PHP Fatal errororPermission denied. If you don't have panel access, contact hosting support. - 2
Temporarily disable .htaccess
Via FTP or file manager, rename
.htaccessto.htaccess.bak. If the site works, the error is in the rules; restore the file and remove the problematic rule. Removing.htaccesstemporarily disables redirects and security rules, so restore it as soon as you finish checking. Before making changes, back up the site and database. - 3
Disable plugins and theme
If you use WordPress, via FTP rename the
wp-content/pluginsfolder toplugins_offand check if the site opens. Then re-enable plugins one by one until you find the problematic one. Do the same with the active theme if needed, but first note the active theme name: without its folder, the site displays without styles or with the default theme, so restore the folder to its original name as soon as you finish checking. - 4
Increase PHP memory and check version
In the hosting panel or in the
wp-config.phpfile, adddefine('WP_MEMORY_LIMIT', '256M');before the linerequire_once ABSPATH . 'wp-settings.php';. The value cannot exceed the limit allowed by the hosting. Also check if the PHP version is compatible with the plugins; if needed, revert to an older version in the panel. - 5
Check file permissions
Via FTP client or file manager, set permissions: folders
755, files644. Forwp-config.php,600or640may be needed. Avoid777as it poses a security risk. - 6
Restore backup if nothing helps
If you cannot identify the cause, restore the last working backup of the site and database. This will undo all recent changes, so first make a copy of the current state for analysis.
If the error persists
If you have disabled all plugins, restored .htaccess and permissions, and the 500 error still occurs, the problem is likely at the server level. Contact hosting support and send them the exact time the error occurs and the last lines of the error log. Note: if you have access to site files (FTP or SSH), you can temporarily enable error logging in wp-config.php with the lines define('WP_DEBUG', true);, define('WP_DEBUG_LOG', true); and define('WP_DEBUG_DISPLAY', false);; errors are then written to wp-content/debug.log. Do not enable error display on a production site, as visitors will see messages and server paths. Disable all three lines (set values to false) as soon as you finish analysis. For high-traffic sites, consider switching to managed hosting that automatically resolves such issues.
How to prevent it
- Regularly back up the site and database (daily or weekly).
- Update WordPress, theme, and plugins on time, but first on a test environment.
- Avoid manual .htaccess changes without a prior backup.
- Monitor the error log and react immediately to recurring errors.
When to call a professional
If you don't have access to error logs, don't know how to use FTP, or the error persists after all steps, call IT support. They can quickly isolate the cause and prevent prolonged site downtime.
Website development · Fast, SEO-ready, multilingual websitesFAQ
Can a 500 error disappear on its own?
Sometimes, if the cause is temporary server overload. If it recurs, be sure to check the logs as the problem is likely to return.
How do I know if the problem is with my site or the hosting?
If the error occurs on all pages and you haven't changed anything, it's likely the hosting. Check the hosting status page or contact them.
Can I fix a 500 error myself without panel access?
It's difficult, as diagnostics usually require error logs and file access. In that case, it's best to contact hosting support or an IT expert.