Common causes
- A plugin or theme update that is incompatible with your PHP or WordPress version
- A PHP fatal error from a syntax error after editing theme files or snippets
- PHP memory limit exhausted
- Two plugins declaring the same function or class
- Upgrading PHP (for example to 8.x) with outdated plugins that call removed functions
- Corrupted or incomplete files after a failed update
How to fix it
- Use the recovery mode email. Check the inbox of the site admin email for a message titled 'Your Site is Experiencing a Technical Issue'. It names the plugin or theme and contains a recovery link that logs you in with it paused so you can deactivate or update it.
- Read the debug log. If no email arrived, add define('WP_DEBUG', true); define('WP_DEBUG_LOG', true); define('WP_DEBUG_DISPLAY', false); to wp-config.php, reload the page and read wp-content/debug.log. The PHP Fatal error line names the file, usually under wp-content/plugins/ or wp-content/themes/.
- Disable the faulty plugin. Rename the plugin's folder over SFTP or the hosting file manager, or run wp plugin deactivate plugin-name with WP-CLI. Reload the site to confirm the error is gone.
- Switch theme if needed. If the error is in the theme, rename the active theme's folder or run wp theme activate twentytwentyfour. Then fix or roll back the theme change.
- Check PHP version and memory. If the error started after a PHP upgrade, temporarily switch back in the hosting panel and update the plugin. For memory errors, add define('WP_MEMORY_LIMIT', '256M'); to wp-config.php.
- Update or replace the code. Update the plugin or theme to its latest version, or roll back to the previous version. If it is abandoned, replace it with a maintained alternative.
wp-config.php (debugging and recovery email)
define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
define( 'WP_DEBUG_DISPLAY', false );
// Optional: send recovery mode emails to a different address
define( 'RECOVERY_MODE_EMAIL', '[email protected]' ); How to stop it happening again
- Test updates on staging before applying them to production
- Check the 'Requires PHP' value before installing plugins
- Make sure the admin email address is valid and can receive mail
- Keep backups that can be restored without logging in to wp-admin