Logo
Bearhost Logo

How to Fix the WordPress White Screen of Death

By Elliot, BearHost·

The WordPress White Screen of Death (WSOD) shows a blank white page with no error message. This makes it one of the most frustrating WordPress errors, but it is usually fixable with systematic troubleshooting.

Common Causes

  • A plugin conflict or incompatible update
  • A broken or incompatible theme
  • PHP memory limit exhaustion
  • Corrupted .htaccess file
  • Database connection issues
  • PHP syntax errors after editing files

Step 1: Enable WP_DEBUG

WordPress hides errors by default. Enable debug mode to see what is going wrong.

Connect to your site via cPanel File Manager or FTP and edit wp-config.php in your WordPress root directory. Find the line:

define( 'WP_DEBUG', false );

Replace it with:

define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
define( 'WP_DEBUG_DISPLAY', false );

This writes errors to wp-content/debug.log without displaying them to visitors. Reload the page and then check the log file for specific error messages.

Step 2: Check the cPanel Error Log

In cPanel, go to Metrics > Errors to view recent PHP errors. This often reveals the exact file and line number causing the problem.

Step 3: Disable All Plugins

A plugin is the most common cause. If you cannot access the WordPress dashboard:

  1. Open cPanel File Manager
  2. Navigate to public_html/wp-content/
  3. Rename the plugins folder to plugins_disabled
  4. Reload your site

If the site loads, a plugin is the culprit. To find which one:

  1. Rename plugins_disabled back to plugins
  2. Open the plugins folder
  3. Rename each plugin folder one at a time, reloading the site after each, until you find the problematic plugin
  4. Once found, delete or replace that plugin

Step 4: Switch to a Default Theme

If disabling plugins does not fix it, the theme may be the issue:

  1. In cPanel File Manager, go to public_html/wp-content/themes/
  2. Rename your active theme folder (e.g., mytheme to mytheme_disabled)
  3. WordPress will automatically fall back to a default theme (Twenty Twenty-Five, etc.)
  4. Reload the site

If the site loads, your theme is the problem. Contact the theme developer or switch to a different theme.

Step 5: Increase PHP Memory Limit

If the debug log shows a memory exhaustion error like Fatal error: Allowed memory size exhausted, increase the limit.

Method 1: wp-config.php

Add before the "stop editing" line:

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

Method 2: .htaccess

Add at the top of your .htaccess file:

php_value memory_limit 256M

Method 3: cPanel MultiPHP INI Editor

  1. Go to MultiPHP INI Editor in cPanel
  2. Select your domain
  3. Find memory_limit and set it to 256M
  4. Click Apply

Step 6: Check and Reset .htaccess

A corrupted .htaccess file can cause a white screen:

  1. In File Manager, find .htaccess in your WordPress root (enable hidden files if you cannot see it)
  2. Rename it to .htaccess_backup
  3. Create a new .htaccess file with the default WordPress rules:
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteBase /
RewriteRule ^index.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

Step 7: Check Database Connection

If you see "Error establishing a database connection" in the debug log:

  1. Open wp-config.php and verify these values:
    • DB_NAME — database name
    • DB_USER — database username
    • DB_PASSWORD — database password
    • DB_HOST — usually localhost
  2. Cross-check in cPanel > MySQL Databases that the database and user exist and are associated
  3. Try logging into phpMyAdmin with the same credentials

Recovery Checklist

If none of the above works:

  1. Restore from your most recent backup (cPanel > JetBackup or Backup Wizard)
  2. Check if the issue appeared after a specific update and roll it back
  3. Re-download and upload fresh WordPress core files (do not replace wp-content)
  4. Contact BearHost support for server-level diagnostics

Preventing Future WSOD

  • Always back up before updating plugins, themes, or WordPress core
  • Update plugins and themes one at a time, not all at once
  • Use a staging site to test updates before applying to production
  • Keep WordPress, plugins, and themes up to date
  • Do not edit theme files directly — use a child theme instead
Tags:#wordpress#wsod#white-screen#debugging#wp-debug#troubleshooting