You open your website and instead of your homepage you get one grey sentence: “There has been a critical error on this website.” Sometimes a second line adds “Please check your site admin email inbox for instructions.” Sometimes even the admin area shows the same message, and you are locked out of everything.
It looks catastrophic. In most cases, it is not. Your content, your pages, and your database are almost always still there. What broke is one piece of code that WordPress tried to run and could not. The job is to find that piece and switch it off.
We’ve seen this message on client websites hundreds of times, with hosting access it’s usually a small fix, website is up and running in less than an hour.
What the message actually means
Before WordPress 5.2, a fatal PHP error produced the infamous white screen of death: a completely blank page with no clue at all. Since 5.2, WordPress catches those fatal errors and shows this friendlier message instead. Same problem, better manners.
A “fatal error” means PHP, the language WordPress is written in, hit something it could not continue past. The usual suspects:
| Cause | Typical trigger |
|---|---|
| Plugin conflict or bug | A plugin was just updated, or two plugins now clash |
| Theme error | A theme update, or a code snippet added to functions.php |
| PHP version mismatch | Your host upgraded PHP and an older plugin or theme can’t run on it |
| Memory limit reached | A heavy page builder or import exceeded the PHP memory limit |
| Corrupted or incomplete update | An update was interrupted halfway, leaving broken files |
Notice the pattern: almost every cause is something changed recently. That is your first clue.
Step 1: Check your inbox before you touch anything
When WordPress catches a fatal error, it sends an email to the site’s administration email address (Settings → General). The subject is something like “Your Site is Experiencing a Technical Issue”.
That email is gold. It usually tells you:
- which plugin or theme caused the error
- the exact file and line where it happened
- a special recovery mode link
The recovery mode link logs you into wp-admin with the faulty plugin or theme paused only for you, while visitors still see the error. From there, you can deactivate the culprit properly. Problem solved in two clicks.
If the email never arrived, check spam. If the admin email address is an old one nobody reads, that is the first thing to fix once the site is back.
Step 2: Ask yourself what changed
Before you go digging in files, answer honestly:
- Did anyone update a plugin, theme or WordPress core today or yesterday?
- Did anyone install a new plugin?
- Did anyone paste code into the theme or a snippets plugin?
- Did your host send an email about a PHP upgrade or server maintenance?
If the answer is yes, you already know where to look. If an update caused it, our article explains why this happens and how to stop it from happening again.
Step 3: Turn on debugging to see the real error
If there is no email and no obvious recent change, make WordPress tell you what is wrong.
Through your hosting file manager (in cPanel: File Manager) or FTP, open wp-config.php in the site’s root folder. Find this line:
define( 'WP_DEBUG', false );
Replace it with:
define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
define( 'WP_DEBUG_DISPLAY', false );
Reload the broken page once. WordPress now writes the error to wp-content/debug.log without showing it to visitors. Open that file and look at the last lines. You are looking for a line starting with PHP Fatal error. It names a file path, and the path tells you who is responsible:
wp-content/plugins/some-plugin/...→ that pluginwp-content/themes/your-theme/...→ your themewp-includes/...orwp-admin/...→ core files, usually a broken update
Many hosts also keep their own error_log file in the site folder or in cPanel under Metrics → Errors. Same information, different place.
Important: set WP_DEBUG back to false when you are done. A debug log left running grows forever and can expose file paths to anyone who guesses its URL.
Step 4: Switch off the culprit
If it’s a plugin
Without wp-admin access, you deactivate a plugin by renaming its folder:
- Go to
wp-content/plugins/ - Rename the guilty folder, for example
some-plugin→some-plugin-OFF - Reload the site
WordPress cannot find the plugin anymore, so it deactivates it. If you don’t know which plugin it is, rename the whole plugins folder to plugins-OFF. If the site comes back, rename it back to plugins and then disable plugins one by one from wp-admin until you find the one that breaks it.
If it’s the theme
Rename your active theme’s folder in wp-content/themes/. WordPress falls back to a default theme (like Twenty Twenty-Five) if one is installed. Your site will look different, but it will load, and you can investigate from wp-admin.
If it’s the PHP version
If the error mentions functions that are “deprecated” or “undefined” and your host recently changed PHP, you can usually switch back temporarily in cPanel (Select PHP Version or MultiPHP Manager). Treat that as a bandage, not a fix: older PHP versions stop receiving security updates. The real fix is updating or replacing whatever can’t run on current PHP.
If it’s memory
An error containing “Allowed memory size of … bytes exhausted” means PHP ran out of memory. You can raise the WordPress limit in wp-config.php:
define( 'WP_MEMORY_LIMIT', '256M' );
Your host’s own limit still applies, so if that doesn’t help, ask them. And ask yourself why a page needs that much memory, because that is often a performance problem in disguise.
Step 5: If nothing works, restore a backup
If you can’t isolate the cause, restoring yesterday’s backup is a legitimate fix. That assumes you have one, it’s recent, and it actually restores. Many site owners discover on this exact day that the backup they counted on lives on the same server or was never tested. We wrote about that in this article.
One warning: if your site takes orders or form submissions, restoring yesterday’s database also deletes everything that came in since. Restore files first, and only roll back the database if you must.
What not to do
- Don’t reinstall WordPress from scratch “to start clean”. You can lose uploads, settings and custom code.
- Don’t delete plugin folders. Rename them. Deleted means gone, including their settings in some cases.
- Don’t edit files without a copy. Download the file before you change it.
- Don’t run more updates hoping one fixes it. You’ll add new unknowns to the existing one.
How to stop seeing this message
A critical error is almost never random. It is the visible result of a change made without testing. The prevention is boring and effective:
- Test updates on a staging copy first, never directly on the live site.
- Keep off-site backups that have actually been restored at least once.
- Use an admin email someone reads, so WordPress’s warning reaches a human.
- Watch your PHP version and update old plugins before the host forces the upgrade.
Still stuck?
If the site is down and you’d rather not edit wp-config.php yourself, that’s exactly what a rescue is for. We find the cause, get the site back, and tell you in plain language what happened and how to prevent it.
If your site is running but you want to know how close it is to this message, start with the free Health Check. It covers updates, PHP version, backups and the other things that usually cause it.