Server error (500) on your site
Find the cause of a 500 Internal Server Error in the error and PHP logs, then fix it with a setting change, a restart, or a rollback.
A 500 error means PHP or WordPress failed while it built the page. The web server is fine, so the fix is in the code, a plugin, the PHP settings, or the database. The error log names the cause in most cases.
How do I find the cause?
- Open the site, then Logs, and pick
php-error.log. Filter by Error. Copy the first fatal line. It names the file and line that failed. - In the same log, look for PHP-FPM pool messages. A worker that ran out of memory or restarted means PHP ran short. Then pick
error.logto see Nginx errors, such as upstream timeouts. - Open User Activity and Deploys on Info. If the 500 started with a deploy, a plugin update, or a PHP change, that change is the first suspect.
How do I fix it?
- Plugin or theme fault. Deactivate the plugin named in the error from wp-admin, or rename its folder over SFTP. Reactivate it after the fix. Try changes on staging first if you can.
- PHP memory error. Open Tools, then PHP settings, and raise the memory limit one step. Change one setting at a time, then restart PHP from Tools.
- Bad deploy. On live's Info page, open Deploys and roll back to the release before the change. Rollback changes code only.
- PHP version change. Switch back under Tools, then test plugins one by one on staging before you switch again.
- Database error. See Database connection errors.
Still stuck
Message Nami from the chat button with the site name, the environment, the time of the errors, the first fatal line from php-error.log, and the job ID of any recent deploy.
Related
Still stuck?
Email support at wpwaterfall dot com with your site name and what you tried, or send us a message.