There Has Been a Critical Error on This Website: How to Fix It in WordPress
"There has been a critical error" or a blank white screen means PHP crashed. Find the plugin or theme behind it, fix it, and keep it from coming back.
What the Critical Error Actually Means
Since WordPress 5.2, when PHP throws a fatal error, WordPress catches it and shows a white screen with the message: “There has been a critical error on this website.” Before that update, you’d get the raw PHP error or a blank page. The new behavior is friendlier to visitors, but less informative for you.
Under the hood, something caused PHP to halt execution entirely. A plugin called a function that doesn’t exist. A theme tried to use a PHP feature your server doesn’t support. A database query failed in a way that WordPress can’t recover from. The “critical error” label is WordPress saying: “I can’t do my job because something upstream broke.”
A blank page with no message at all is the older form of the same failure, the WordPress white screen of death (WSOD). The steps below fix both; the white screen of death guide covers what is different when you get no message at all. If the browser shows “500 Internal Server Error” instead, the crash happened before WordPress could catch it: follow the WordPress 500 error fix.
Step 1: Check Your Email
WordPress sends a recovery mode email to the admin email address when a critical error occurs. This email contains a link that lets you log into WordPress in recovery mode, with the offending plugin or theme automatically paused.
Check your inbox and spam folder. The email comes from “WordPress” at your domain. If you find it, click the recovery link, deactivate the problematic plugin or theme, and the site comes back.
If you don’t have the email (maybe the admin email is outdated, or your server can’t send mail), you’ll need to fix it manually.
The recovery mode email didn’t arrive
Check which address WordPress sends to: it’s the Administration Email Address under Settings > General, which is often an old employee’s or a developer’s inbox. If the site can’t send mail at all, the email never leaves the server. Either way, skip ahead: debug mode and renaming folders work without it.
Step 2: Enable Debug Mode
Without seeing the actual error, you’re guessing. Edit wp-config.php (via SFTP or your hosting file manager) and add or change these lines:
define('WP_DEBUG', true);
define('WP_DEBUG_LOG', true);
define('WP_DEBUG_DISPLAY', false);
This writes errors to wp-content/debug.log without showing them to visitors. Reload the broken page, then check that file. The error message tells you exactly what failed and which file caused it.
A typical entry looks like: Fatal error: Uncaught Error: Call to undefined function some_function() in /wp-content/plugins/some-plugin/file.php on line 42. That tells you the plugin name and the exact problem.
How to read the most common debug.log lines:
- Call to undefined function: a plugin or theme depends on code that isn’t loaded, usually a missing or deactivated companion plugin, or a PHP extension the server doesn’t have.
- Allowed memory size exhausted: PHP ran out of memory. Raise WP_MEMORY_LIMIT, then find what is using so much.
- Cannot redeclare: two plugins define the same function, or a plugin is installed twice.
- syntax error, unexpected: a file was edited by hand or only half-updated. The path in the message shows which one.
Step 3: Deactivate the Offending Plugin or Theme
If you can access wp-admin (sometimes the error only affects the front end), go to Plugins, find the culprit, and deactivate it.
If you can’t access wp-admin, rename the plugin’s folder via SFTP. For example, rename wp-content/plugins/broken-plugin to wp-content/plugins/broken-plugin-disabled. WordPress will deactivate it automatically because it can’t find the folder.
If the error is theme-related, rename your active theme’s folder. WordPress will fall back to a default theme (like Twenty Twenty-Four) and the site will come back online.
Critical error or white screen still there after these steps? Get a human on it: WordPress critical error emergency help →
Step 4: Identify the Root Cause
Knowing which plugin broke is step one. Knowing why it broke prevents recurrence. Common causes:
- PHP version incompatibility. The plugin requires PHP 8.1+ but your server runs 7.4. Or your host upgraded PHP and the plugin hasn’t caught up.
- Plugin update conflict. Plugin A updated its code, and Plugin B depends on the old behavior. This is especially common with page builders and their add-on ecosystems.
- Memory limit exhaustion. WordPress ran out of allocated memory during a heavy operation. Increase the limit in
wp-config.php:define('WP_MEMORY_LIMIT', '256M'); - Corrupted plugin files. An incomplete update left partial files. Delete the plugin folder and reinstall fresh from the repository.
Critical error right after a plugin update
If the message appeared minutes after you clicked Update, the update is the cause until proven otherwise. Roll that one plugin back to its previous version (or restore the pre-update backup), confirm the site loads, then read how to prevent WordPress plugin conflicts before you try again. Recovering from a failed WordPress update covers the rollback step by step.
Step 5: Restore from Backup If Needed
If the error happened after a batch update and multiple plugins are involved, a backup restore is often faster than debugging each conflict. Roll back to the state before the updates, then apply them one at a time to isolate the problem.
If you don’t have backups (and that’s more common than it should be), this is the moment where the pain of not having them becomes real. A managed WordPress operations service like Parameter Protect includes daily tested backups with verified recovery, so you always have a clean rollback point.
Blank White Screen Instead of the Critical Error Message?
A completely blank page with no message at all is the WordPress white screen of death (WSOD). It’s the same kind of PHP fatal error, but severe enough (memory exhaustion is the usual one) that WordPress couldn’t show the critical error notice, or a cache is serving a blank copy of the page. Steps 2 to 5 above apply, but the white screen has its own checks: where it’s white (whole site, front end only, wp-admin only, one page), clearing every cache, and reading the server log when debug.log stays empty. Follow the full WordPress white screen of death fix.
If there is no critical error message and the site simply won’t load at all, the cause is usually upstream of PHP: work through the WordPress site down checklist instead (down for everyone or just you, host, DNS, then the error code).
When to Call for Help
Some critical errors are straightforward: deactivate the plugin, contact the developer, wait for a fix. Others point to deeper problems: corrupted database tables, server misconfigurations, or malware that’s modifying core files.
If this keeps happening, the critical error or white screen is a symptom of something deeper. Start with a free audit to find the root cause.
If the error keeps coming back, if multiple plugins are failing, or if you see errors referencing files you don’t recognize, the problem may be bigger than a single plugin. Parameter’s emergency diagnostic gets to the root cause fast: 60 minutes of hands-on work for $99 flat, fixing what fits in that window and leaving you a clear action plan for the rest. The $99 is credited toward a Protect plan started within 7 days.
Turn debug mode off when you’re done: define('WP_DEBUG', false);. Leaving it on in production exposes error details that attackers can use.
WordPress Critical Error FAQ
What does “There has been a critical error on this website” mean?
PHP hit a fatal error while loading the page and WordPress’s recovery handler caught it. In most cases a plugin or the theme is calling code that no longer exists or isn’t compatible with your PHP version. Your content is still in the database; the page just can’t be built until the faulty code is fixed or switched off.
I didn’t get the recovery mode email. What now?
Check spam and the admin email address under Settings > General (it may be an old address). If it never arrives, enable WP_DEBUG_LOG in wp-config.php, reload the page, and read wp-content/debug.log: the last fatal error names the plugin or theme file. Then disable that plugin by renaming its folder over SFTP.
How do I find which plugin caused the critical error?
The debug log or the recovery email names the file, and the folder after wp-content/plugins/ in that path is the plugin. If you have no log, rename the whole plugins folder, confirm the site loads, then bring plugins back one at a time until the error returns.
Why did the critical error appear after a PHP or WordPress update?
The update exposed code that was already outdated: an old plugin or theme using functions that newer PHP versions removed. Update or replace that plugin, or temporarily switch PHP back in your hosting panel while you do. Test the next update on staging first.
Can someone fix the critical error for me right now?
Yes. Parameter’s emergency WordPress support is a $99 flat, 60-minute session with a senior engineer, who is typically hands-on within the hour during US business hours.
Want WordPress to feel handled?
Self-serve onboarding takes minutes. Parameter takes care of the rest, hosting, ops, and improvements when you need them.