Troubleshooting · Troubleshooting
How to Fix the WordPress White Screen of Death in WordPress
Short answer
The white screen of death is a PHP fatal error that stops WordPress before it can send any page to the browser. Turn on WP_DEBUG_LOG in wp-config.php, reload the blank page, then read wp-content/debug.log to find the file that failed. Fix that plugin, theme or memory limit, then turn debug logging off again.
Key takeaways
- The white screen is a PHP fatal error that stops the page before any HTML loads.
- Since WordPress 5.2, most fatal errors show a critical error message and a recovery link instead.
- WP_DEBUG_LOG writes the real error to wp-content/debug.log.
- WordPress aims for 40 MB of memory on a single site and 64 MB on multisite.
- Turn debug logging off and delete debug.log after the fix.
What is the WordPress white screen of death?
The white screen of death is a PHP fatal error that stops WordPress before it can send any page to the browser.
You see a blank page with no text and no error code. The error itself is hidden, because most hosts turn off error display on live sites.
WordPress.org's common errors guide says both PHP errors and database errors can show up as a white screen. The guide calls it the WordPress White Screen of Death, or WSOD.
The debugging guide from WordPress explains why the page stays blank. PHP's default is to only display fatal errors or show a white screen of death when errors are reached. See Debugging in WordPress.
What should you check first?
Check whether wp-admin still loads before you change any files.
If the dashboard works, the fault is likely in your theme or in a plugin that only runs on the front end. Go to Plugins and deactivate the plugin you changed most recently, then reload the site.
If the dashboard is blank too, the fault is deeper. You will need FTP or your host file manager for the steps below, so open that now.
Back up the site before you edit files. If the screen went blank right after an update, the update itself is the first suspect. WordPress.org's common errors guide lists a failed auto-update as one cause of a blank white screen.
How do you use Recovery Mode?
Recovery Mode is the fastest way back in when a plugin or theme crashes the site.
WordPress 5.2 introduced Recovery Mode, which shows an error message instead of a white screen when a plugin causes a fatal error. The developer handbook on editing wp-config.php gives the message as "The site is experiencing technical difficulties. Please check your site admin email inbox for instructions."
When the crash happens, WordPress emails the site admin address with a special login link. Click that link to log in with the faulty plugin or theme paused for your session.
Once you are in, deactivate the plugin or switch the theme, then log out of Recovery Mode. If no email arrived, check spam, then move on to debug logging below.
How do you turn on debug logging?
Turn on debug logging to make WordPress write the real error to a file.
Open wp-config.php in your site root and add these lines above the line that says “That's all, stop editing! Happy blogging.”:
define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
define( 'WP_DEBUG_DISPLAY', false );
The debugging guide says WP_DEBUG_LOG saves all errors to a debug.log file in the content directory, usually wp-content/debug.log. See Debugging in WordPress.
WP_DEBUG_DISPLAY set to false keeps the errors off the page, so visitors still see a blank page while you read the log. The same guide warns that these tools are meant for local and staging installs, not live sites.
How do you read the debug log?
Reload the blank page once, then open wp-content/debug.log through FTP or your host file manager.
Look for the last line that says “Fatal error” or “Parse error”. That line names the file and the line number where PHP stopped.
The folder name in the file path tells you which plugin or theme broke. A path with /plugins/contact-form-7/ points at that plugin, while a path with /themes/ points at the theme.
| Error text | What it means | Fix first |
|---|---|---|
| Fatal error | PHP stopped on a bad file | Disable the named plugin or theme |
| Parse error | A syntax error in a PHP file | Fix the named file or restore it |
| Allowed memory size exhausted | PHP ran out of memory | Raise WP_MEMORY_LIMIT to 256M |
| Maximum execution time exceeded | A task ran too long | Raise max_execution_time or ask the host |
If the log is empty, the error may have happened before WordPress loaded. Check your host error log instead, or ask your host where PHP errors are written.
How do you find a bad plugin?
Rename the plugins folder to turn every plugin off at once without the dashboard.
WordPress.org's common errors guide says to log in by FTP, find wp-content/plugins, and rename the folder to plugins_old. That deactivates all plugins at once.
Reload the site. If it comes back, a plugin caused the crash. Rename the folder back to plugins, then reactivate plugins one by one from the dashboard until the screen goes blank again.
The last plugin you reactivated is the culprit. Leave it off and check for an update or a replacement. If the site stays blank with all plugins off, the fault is in the theme or in core files.
How do you find a bad theme?
Switch to a default WordPress theme to rule out your active theme.
This is most likely the cause if the white screen started right after you activated a new theme. WordPress.org's common errors guide suggests activating a default theme from the dashboard.
If you cannot reach the dashboard, rename the active theme folder in wp-content/themes by FTP. WordPress then falls back to a default theme on its own.
If the site loads with the default theme, your theme has a fatal error. Contact the theme author or restore the theme from a backup. A theme conflict can look like a plugin problem, so test the theme even when the log names a plugin file.
How do you fix a memory limit crash?
Raise the WordPress memory limit when the log says “Allowed memory size exhausted”.
WordPress aims for 40 MB of memory on a single site and 64 MB on a multisite install. The developer handbook on editing wp-config.php says the setting in wp-config.php should be higher than those numbers.
Add this line above the “That's all, stop editing!” line:
define( 'WP_MEMORY_LIMIT', '256M' );
The PHP manual lists the default memory_limit as 128M, so 256M gives a busy site room to run. See the PHP manual on core php.ini directives.
If raising the limit fixes the screen, a plugin or theme is using too much memory. Find it with the plugin steps above instead of raising the limit again. Our guide to fixing the allowed memory size error covers this in detail.
How do you repair broken core files?
Replace damaged core files and .htaccess when plugins, themes and memory all check out.
Download a fresh copy of WordPress and re-upload only the wp-admin and wp-includes folders. WordPress.org's common errors guide lists this as a fix for an Internal Server Error, and it works for a white screen too.
Do not overwrite wp-content or wp-config.php, because those hold your uploads, plugins, themes and settings. A fresh copy of those two folders only replaces core code.
A damaged .htaccess file can also blank the site. Rename it to .htaccess_old by FTP, then go to Settings > Permalinks and save to build a fresh one. If a bad .htaccess line broke your site, see our guide to fixing the 500 Internal Server Error.
How do you confirm the fix worked?
Load the home page and two more pages in a private browser window.
All three should load with no blank screen. Then log in to wp-admin and check that the dashboard, the post list and the plugin list all open.
Turn debug logging off now. Set WP_DEBUG and WP_DEBUG_LOG back to false in wp-config.php, and delete wp-content/debug.log. The debugging guide warns that the log file can sit in a public folder, so leaving it there leaks file paths.
WooCommerce's system status report shows WP Debug Mode and WP Memory Limit fields, which is a quick way to confirm both are back to normal on a store.
When should you call your host?
Call your host when the log points at the server, or when no step above brings the site back.
Ask for the PHP error log if debug.log stays empty. Ask whether the server ran out of memory or disk space, and whether a recent server change broke the site.
WordPress.org's Site Health guide says loopback requests run scheduled events and verify code in the theme and plugin editors. If Site Health reports that loopback requests fail, your host must fix that.
WordPress.org recommends PHP 8.3 or greater, so ask your host to confirm your PHP version too. If the site still fails after a core reinstall, the fault may be in the database, so read our guide to fixing the database connection error.
Frequently asked questions
Why is my site blank but wp-admin still works?
The two faults are different. A blank front end with a working dashboard points at the theme or a plugin that only runs on the front end. Test by switching to a default theme. If the dashboard is blank too, the fault is deeper, so use FTP and debug logging to find it.
Is the white screen of death the same as the critical error message?
They are two faces of the same problem. Since WordPress 5.2, the fatal error handler usually shows the critical error message and emails a recovery link instead of a blank page. A pure white screen means the handler never ran, or the error happened before WordPress loaded. Both need the debug log to find the cause.
Should I leave WP_DEBUG turned on?
No. Leave it on only while you find the fault. The debugging guide says these tools are meant for local and staging installs, not live sites. Set WP_DEBUG and WP_DEBUG_LOG back to false when the site works again, and delete wp-content/debug.log, because it can sit in a public folder.
What if debug.log is empty?
An empty log means the error happened before WordPress could write to it, or the log path is wrong. Check your host error log, which records PHP errors at the server level. A blank page with no log entry often points at a broken .htaccess file, a PHP version problem, or a server limit.
Can a white screen mean my site was hacked?
It is possible, but it is not the first suspect. WordPress.org's common errors guide says that if wp-config.php is correct and the host reports no issue, a hacked site is possible and suggests scanning the site. Check the log first: a named plugin or theme file is a far more likely cause than a hack.
How long does it take to fix a white screen?
Most cases take under an hour once the debug log names the file. Renaming the plugins folder takes minutes, and reactivating plugins one by one takes longer on sites with many plugins. If no log entry appears and the host finds nothing, allow more time for a deeper check.
Sources
- Common WordPress errors WordPress.org Documentation
- Debugging in WordPress WordPress Developer Resources
- Editing wp-config.php WordPress Developer Resources
- Site Health screen WordPress.org Documentation
- Description of core php.ini directives PHP Manual
- Understanding the WooCommerce System Status Report WooCommerce
Is your product missing, or something out of date?
Tell us what to add or correct. We read every note and reply when we need a source. A message does not buy a ranking.
Thanks — we review requests within 3 business days.
