Error message · WordPress

“There has been a critical error on this website.”

WordPress hit a PHP error it couldn't recover from, so it stopped building the page and showed this message instead. Visitors see only that sentence. Since WordPress 5.2 it also emails the site's admin address a link to recovery mode, where you can log in with the broken plugin or theme paused.

Is your site showing it right now?

The free scan loads your page like a visitor and checks for this message, plus broken links, script errors and phone layout. It also walks your signup, booking or contact form, without sending anything.

​

Free, no signup. Usually done in about a minute.

Why it happens

  • A plugin or theme update with a bug, or one that doesn't work with your WordPress version
  • Your host changed the PHP version, and a plugin or theme doesn't support the new one
  • Two plugins that conflict with each other
  • The site ran out of PHP memory

How to fix it

  1. Check the admin email inbox

    Look for an email from WordPress with the subject "Your Site is Experiencing a Technical Issue". It names the plugin or theme that failed and has a recovery-mode login link. Log in through it and deactivate or update that plugin or theme.

  2. No email? Find the cause in the error log

    In wp-config.php, set define('WP_DEBUG', true); and define('WP_DEBUG_LOG', true); then load the page again and open wp-content/debug.log. The last "Fatal error" line names the file, and the folder it's in names the plugin or theme. Set WP_DEBUG back to false when you're done.

  3. Deactivate the plugin without logging in

    With your host's file manager or FTP, rename its folder in wp-content/plugins (for example add "-off" to the end). WordPress deactivates a plugin whose folder it can't find. For a theme, rename its folder in wp-content/themes and WordPress falls back to a default theme.

  4. Undo a PHP version change

    If your host recently upgraded PHP, switch back to the previous version in the hosting control panel, then update the plugin or theme before upgrading again.

  5. Raise the memory limit

    If the log mentions "Allowed memory size exhausted", add define('WP_MEMORY_LIMIT', '256M'); to wp-config.php, or ask your host to raise the PHP memory limit.

Questions

Is my content lost?

No. Your posts, pages and settings are in the database and untouched. Once the failing plugin or theme is fixed or turned off, the site comes back as it was.

Why do some pages work and others don't?

The broken code only runs on some pages, like a shop plugin on product pages. Pages that don't use it still load.

Can Page Canary tell me if this comes back?

Yes. Page Canary checks your key pages every day for this message and others like it, confirms it on a second check, and emails you with the fix. One site is free.

Other error messages