WordPress troubleshooting

Fix common WordPress errors.

One page per error, written for somebody whose site is down right now. Each starts with the message as WordPress writes it, then the causes in the order worth checking them.

Errors

Find the message you are seeing.

Match the wording rather than the symptom - a blank page and a 500 look identical in a browser and are different problems underneath.

Error establishing a database connection

WordPress loaded, read wp-config.php, and could not get an answer from MySQL. Every page on the site is blank until it can.

The WordPress white screen of death

A completely blank page with no error and no HTML. PHP stopped mid-request and the message went to a log you have not read yet.

500 Internal Server Error

The web server tried to produce the page, something went wrong inside, and it returned a status code instead of a reason.

502 Bad Gateway

The web server reached PHP and PHP did not answer. Nginx or Apache is reporting a conversation that ended before it started.

504 Gateway Timeout

PHP was still working when the web server gave up waiting. Nothing crashed - it simply took longer than the timeout allows.

Allowed memory size exhausted

PHP reached the ceiling it was given and stopped. The number in the message is the limit, not the amount your site needs.

Maximum execution time exceeded

PHP stopped a script that had been running longer than it is allowed to. The limit did its job; the question is whether the job belonged in a web request.

ERR_TOO_MANY_REDIRECTS

The browser followed redirect after redirect and stopped. Two things disagree about where this URL should live, and each is confident.

There has been a critical error on this website

WordPress's own fatal error handler. It caught a crash, replaced the page with this sentence, and told nobody except the admin email.

Briefly unavailable for scheduled maintenance

WordPress writes a .maintenance file before an update and removes it after. The update did not finish, so the file is still there.

Or stop debugging your host.

Most of these are configuration rather than WordPress. Managed hosting with daily backups, one-click staging and per-site limits takes the common causes off the list.