There Has Been a Critical Error on This Website: How to Fix It

Short answer: “There has been a critical error on this website” means a PHP fatal error stopped WordPress from loading, usually caused by a plugin, a theme, the PHP version or the memory limit. Check your site admin email for WordPress’s recovery-mode link first. If there is no email, turn on the debug log to find the file causing the error, then deactivate that plugin or theme from your hosting File Manager or FTP. If nothing works, restore a backup or ask your host.

You open your website, or a customer texts you a screenshot, and instead of your homepage there is one plain line: “There has been a critical error on this website.” Sometimes it adds “Please check your site admin email inbox for instructions” and a link that says “Learn more about troubleshooting WordPress.”

It looks scary, but it is one of the most fixable WordPress problems. Your content is almost always still there. Something in the code (very often one plugin) crashed while the page was loading, and WordPress stopped instead of showing a broken page.

This guide walks you through the fix in the order that solves it fastest, with no coding background required. The technical details come from the official WordPress documentation, linked at the end.

What the critical error actually means

Since WordPress 5.2, WordPress catches “fatal” PHP errors and shows this friendly message instead of a blank white page (the old “white screen of death”). At the same time, it tries to email the site’s admin email address with details and a special recovery link.

WordPress’s own troubleshooting docs list the most common causes:

  • A plugin conflict or a broken plugin update
  • A theme compatibility problem, often right after a theme update or switch
  • An incompatible PHP version, for example an old plugin on a newer PHP version, or the other way around
  • Hitting the PHP memory limit
  • Corrupted WordPress files, for example after a failed update

Before you change anything, ask yourself one question: what changed just before the error appeared? An update, a new plugin, a theme edit, a PHP upgrade by your host? That answer usually points straight at the culprit.

Before you start: a quick safety checklist

  • Make a backup if your host lets you take one now, even of the broken site. Many hosting panels have a one-click backup or a list of automatic backups.
  • Have your hosting login ready. You will need either the host’s File Manager (most hosts, including Hostinger, cPanel-based hosts and others, have one in their dashboard) or an FTP/SFTP app with your FTP details.
  • Change one thing at a time and reload the site after each change, so you know what fixed it.

Step 1: Check your admin email for the recovery mode link

Look in the inbox of the email address set as the site’s admin email (check spam too). WordPress sends a message with a subject like “[Your Site Name] Your Site is Experiencing a Technical Issue.”

The email usually tells you which plugin or theme caused the error and includes a recovery mode link. To use it:

  1. Click the recovery link in the email and log in to WordPress.
  2. You will see a notice that recovery mode is on and which plugin or theme was paused.
  3. Go to Plugins (or Appearance > Themes) and deactivate the extension that caused the error.
  4. Click Exit Recovery Mode in the top admin bar, then check your site in a private browser window.

Two things to know. First, recovery mode only pauses the broken plugin for you; visitors still see the error until you actually deactivate, update or replace it. Second, the link expires (by default after about a day). If it has expired, WordPress sends a new one if the error happens again.

No email? That is common. The admin email may be an old address, or your server may not send mail reliably. Move on to Step 2.

Step 2: Turn on the debug log to see the real error

The “Learn more about troubleshooting WordPress” link on the error screen leads to WordPress’s general troubleshooting FAQ. To see the exact error on your own site, use WordPress’s built-in debug log.

  1. Open your hosting File Manager (or FTP) and go to the folder where WordPress is installed, often called public_html.
  2. Find the file wp-config.php, download a copy as a backup, then edit it.
  3. Look for a line that says define( 'WP_DEBUG', false );. Change it, or add these lines above the line that says /* That's all, stop editing! Happy publishing. */ (older installs say “Happy blogging”):
define( 'WP_DEBUG', true ); define( 'WP_DEBUG_LOG', true ); define( 'WP_DEBUG_DISPLAY', false );
  1. Save the file and reload your website once so the error happens again.
  2. Open the wp-content folder and look for a new file called debug.log. Open it and scroll to the bottom.

Look for a line starting with “PHP Fatal error.” It usually includes a file path, such as /wp-content/plugins/some-plugin-name/... or /wp-content/themes/your-theme/.... The folder name after plugins/ or themes/ tells you exactly which plugin or theme is failing. A line containing “Allowed memory size of … bytes exhausted” means you hit the memory limit (see Step 5).

Important: WordPress recommends not leaving debugging on for a live site. When you are done, set WP_DEBUG back to false and delete the debug.log file, because it can contain information about your server.

Step 3: Deactivate plugins without logging in

If you can’t get into your dashboard, you can still turn plugins off from your hosting files.

Option A: Deactivate one plugin (if the log named it)

  1. In File Manager, go to wp-content/plugins.
  2. Find the folder named in the error (for example some-plugin-name).
  3. Rename it, for example to some-plugin-name-off.
  4. Reload your site. WordPress can no longer find that plugin, so it deactivates it.

Option B: Deactivate all plugins at once

  1. Go to wp-content and rename the whole plugins folder to plugins_old.
  2. Reload your site. If it loads, a plugin was the cause.
  3. Rename the folder back to plugins. Your plugins will now show as deactivated in Plugins.
  4. Log in and reactivate them one at a time, reloading the site after each. When the error comes back, you have found the problem plugin. Leave it deactivated.

Then check whether that plugin has an update, look at its support forum, or replace it with a well-maintained alternative.

Step 4: Switch to a default theme

If plugins are not the problem, or the log points to a theme file, test your theme.

  • If you can log in: go to Appearance > Themes and activate a default WordPress theme such as one of the “Twenty” themes (Twenty Twenty-Four, Twenty Twenty-Five and so on).
  • If you can’t log in: in File Manager, go to wp-content/themes and rename your active theme’s folder (for example your-theme to your-theme-off). WordPress will fall back to a default theme if one is installed. If no default theme folder exists, upload one from WordPress.org first.

If the site loads with the default theme, the problem is in your theme or in a recent edit to its files, often functions.php. Undo the last edit, update the theme, or contact the theme developer.

Step 5: Check your PHP version and memory limit

PHP version

WordPress recommends PHP 8.3 or greater. It still runs on PHP 7.4 and up, but those older versions have reached end of life. A critical error can appear in two situations:

  • Your host upgraded PHP and an old plugin or theme isn’t compatible yet.
  • You are on a very old PHP version and a recently updated plugin needs a newer one.

Most hosting dashboards have a PHP version setting. If the error started right after a PHP change, temporarily switch back to the previous version, then update or replace the incompatible plugin and switch forward again. Staying on old PHP long term is a security risk.

Memory limit

If the debug log says “Allowed memory size of … bytes exhausted,” WordPress ran out of PHP memory. You can raise the WordPress memory limit by adding this line to wp-config.php, above the “stop editing” line:

define( 'WP_MEMORY_LIMIT', '256M' );

Some hosts don’t allow this setting to raise the limit. In that case, change it in your host’s PHP settings or ask support. WordPress also warns that raising memory can hide the real problem, so if one plugin keeps eating memory, it is still worth replacing it.

Step 6: Restore a backup

If you can’t find the cause, or the error came right after an update you can’t undo, restore the most recent backup from before the error started. Most hosts keep automatic backups in the hosting dashboard, and many backup plugins store copies off the server.

Keep in mind that restoring replaces your files and database with the older copy, so changes made after that backup (new orders, form entries, blog posts) may be lost. Write down anything recent you need to re-add.

Step 7: Re-upload WordPress core files or contact your host

If plugins, theme, PHP and memory are all fine, WordPress core files may be damaged, for example after an interrupted update. A developer can re-upload fresh wp-admin and wp-includes folders from WordPress.org without touching your content.

This is also the right moment to contact your host’s support. Tell them:

  • The exact error message and when it started
  • What changed just before (update, new plugin, PHP change)
  • What you already tried (renaming plugins, default theme, memory limit)
  • The “PHP Fatal error” line from debug.log, if you have it

Hosts can check server error logs you may not be able to see.

How to avoid the next critical error

  • Back up before updates, especially big plugin, theme or WordPress updates.
  • Update regularly, not all at once after months, so problems are easy to trace.
  • Keep plugins lean. Delete plugins you don’t use, and avoid abandoned or “nulled” (pirated) plugins.
  • Use a staging copy for big changes if your host offers one.
  • Keep the admin email current so the recovery email reaches you.

If you are tired of maintenance and are wondering whether WordPress is still the right platform, our comparison of Webflow vs WordPress vs Wix explains the trade-offs. For budgeting ongoing upkeep, see what a small business website really costs, and if a rebuild is on the table, read how to plan your website before hiring a web developer.

Want someone to fix it for you?

If you’d rather not edit wp-config.php or rename folders on a live business site, Boostology handles WordPress fixes and ongoing website maintenance, so your site stays up while you focus on customers.

FAQ

Did I lose my website content?

Usually not. A critical error stops pages from loading, but your posts, pages and settings stay in the database. Fixing the plugin, theme or PHP issue normally brings everything back.

Why didn’t I get the recovery mode email?

The admin email may be outdated or the email went to spam, or your server may not be able to send mail. Use the debug log (Step 2) instead.

Can I fix the critical error without logging in to WordPress?

Yes. Use your hosting File Manager or FTP to rename the plugin or theme folder causing the error, or edit wp-config.php to turn on the debug log.

Is it safe to rename the plugins folder?

Yes. Renaming only deactivates the plugins; it doesn’t delete them or their settings. Rename it back to plugins and reactivate them one by one.

Should I leave WP_DEBUG turned on?

No. WordPress recommends debugging tools for testing, not live sites. Turn it off and delete debug.log once you’ve found the problem.

Sources

Checked on November 27, 2026.

Need help growing your business online? TopReq is run by the team at Boostology, a web design and digital marketing agency.

Services: Website Design, SEO, Social Media Management, Meta Ads.

Book a free strategy call →