One of the most common WordPress errors is the white screen of death. It’s also one of the most aggravating because there’s no error message and you’re locked out of WordPress.
One more issue with the white screen of death error is it might just affect a portion of your site.
For instance, you will see just a white screen of death within the WordPress admin area though everything else is functioning correctly. In other cases, you may only see it on a single post while everything else works normally.
In this article, we will look at various solutions for resolving the WordPress white screen of death.
Make sure you have a backup of your WordPress site before making any changes to it. If you do not have admin access, please see our guide on how to manually create a WordPress database backup.
Why Is There a White Screen of Death in WordPress?
Amount of times, a white screen of death indicates that a script on your website must have reached its memory limit.
Your WordPress hosting server will either kill the unresponsive script or it will simply time out. As a result, no actual error message is generated, and you are presented with a blank white screen.
Instead of a blank white screen, you may occasionally see a critical error message.
It’s the same error whether you see a blank screen or the message “There has been a critical error on your website.”
This error can also occur as a result of a poorly coded theme or plugin that has been installed on your site. It can happen if there is a problem with your web hosting server.
Because the white screen error can always be triggered by a variety of factors, it needs methodical troubleshooting to resolve.
Is this a problem on any of your other sites?
If you have other WordPress sites installed on the same hosting account, you should first check to see if the problem is present on those sites as well.
If it is, it is a clear indication that something is wrong with your WordPress hosting service. This could be a temporary issue affecting their service, and you should contact their support for further assistance.
If, on the other hand, the problem only occurs with one website or a specific section of that website, you know that the problem is with that specific website.
Using WordPress Recovery Mode to Resolve a White Screen Error
WordPress may be able to detect the white screen of death error if it is caused by a WordPress plugin or theme.
Because of the latest fatal error safety feature introduced in WordPress 5.2, you might not see a white screen. Rather, you can see a message indicating also that the site is experiencing issues.
You would also receive an email with the subject ‘Your Site is Having a Technical Issue’ to your admin email address.
This email message will identify the plugin that is causing the error and will include a special link. This link will take you to the WordPress recovery mode, where you can deactivate the faulty plugin.
Moreover, when you see a plain white screen of death without any email or recovery mode options, you should manually correct the error.
Increasing Memory Capacity
Typically, this error occurs when a script runs out of memory and terminates in the middle of its execution. To resolve this, you must increase the amount of PHP memory available to WordPress. It will enable the script using more memory to complete the task at hand.
All Plugins Are Disabled
If increasing the memory limit did not help, or if you have a large memory limit, such as 256M or 512M, you should begin troubleshooting.
In our experience troubleshooting this issue, we’ve always discovered that the problem is with a specific plugin or a theme. Let’s disable all of the plugins now.
If you still have access to the WordPress admin area, simply navigate to the Plugins » Installed Plugins page. Select all of the installed plugins, then click the ‘Deactivate’ button in the ‘Bulk Actions’ drop-down menu.
If you do not have access to the WordPress admin area, you must deactivate all plugins via FTP.
To begin, use an FTP client to connect to your WordPress site. Once connected, navigate to the wp-content folder and look for the ‘plugins’ folder.
You must now right-click on the plugins folder and select rename. The plugins folder can be renamed plugins-deactivated.
The plugins folder will now be renamed by your FTP client.
To load all plugins, WordPress looks for a folder called plugins. When it is unable to locate the folder, it simply deactivates all plugins.
If this resolves the problem, enable one plugin at a time to get to the bottom of the problem. Once you’ve identified the plugin that’s causing the problem, you can either replace it with a different plugin or report the problem to the plugin’s authors.
Change the original theme with the default theme.
If the plugin troubleshooting does not resolve the problem, you should start by replacing your current theme with a default theme.
To begin, use an FTP client to connect to your website and navigate to the /wp-content/themes/ folder. It contains all of the themes that have been installed on your website.
Right-click on your current WordPress theme to download it as a backup to your computer.
Following that, you must remove your current theme from your website. Select ‘Delete’ from the context menu when you right-click on your theme folder. The theme will now be removed from your website by your FTP client.
Now, if you have a default WordPress theme installed on your website, such as (twenty-eighteen or twenty-nineteen), WordPress will use it as the default theme.
However, if you do not already have a default theme installed, you must manually install it via FTP.
If this resolves the problem, you should take a look at your theme’s functions.php file. If there are any extra spaces at the bottom of the file, remove them; this will sometimes solve the problem.
If you use a poorly coded function in your theme’s functions.php file, it can also result in the white screen of death error.
Consider downloading and installing a fresh copy of your theme from its source.
Enable Debug Mode in WordPress to Catch Errors
If nothing else has worked, the next step is to enable debugging in WordPress. This will allow you to see the types of errors that are being generated.
Simply paste the code below into your wp-config.php file.
- define(‘WP DEBUG’, false);
2. define( ‘WP DEBUG LOG’, false );
Once you’ve done that, the blank screen will have errors, warnings, and notices. These may be able to assist you in determining the underlying cause.
Even if you don’t see any errors, you should still look at the debug log. Using an FTP client, navigate to your website’s wp-content folder. There will be a new debug.log file there, which will contain a log of all errors, notices, and warnings.
WordPress Cache should be cleared.
You may have access to the backend at times, but the front end of the site displays the white screen of death. This can occur as a result of a caching plugin. Simply clear your cache.
Resolving Longer Articles
If you only have a white screen of death on a really lengthy post or page, this little trick might also help.
By increasing the recursion and backtrack limits, this trick essentially increases PHP’s text processing capability. You can insert the code below into your wp-config.php file.
- /** Long-posting Tip */
2. ini set(‘pcre.recursion limit’,20000000);
3. ini set(‘pcre.backtrack limit’,10000000);
We understand that this is a very frustrating error, and we hope that one of the solutions listed above has resolved the problem for you. You may also be interested in our WordPress troubleshooting guide, which teaches you how to detect and resolve WordPress issues on your own.
If you liked this post, please find and follow us on Instagram, Twitter and Facebook.