White screen of death trying accessing the backend: how to find the root cause in a few easy steps

Imagine you want to log in to your WordPress backend, but you always see a white screen of death instead of the usual log-in form.

From version 1.8.8.8.5 and above Freesoul Deactivate Plugins provides an emergency mode to be able to troubleshoot in most cases.

Just follow these steps:

  1. Add to wp-config.php the following line of code before the comment /* That’s all, stop editing! Happy blogging. */
    define( 'FDP_EMERGENCY_LOG_ADMIN','tkej3j43kkkd' );

    Replace “‘tkej3j43kkkd” with whatever you want. This is a secret key that you will use in the next step.

  2. Visit the admin page after adding “?debug=’tkej3j43kkkd” to the URL. Where “‘tkej3j43kkkd” should be replaced by a secret key of your choice. In this example, if your backend is reachable at https://yourdomain.com/wp-admin, you will need to visit it at https://yourdomain.com/wp-admin?debug=’tkej3j43kkkd.
  3. Follow the instructions given by Freesoul Deactivate Plugins. Very probably they will guide you to the solution in a couple of minutes.

 

As you will see, FDP will suggest you add some code in wp-config.php that will look like:

define( "FDP_EMERGENCY_ADMIN_PLUGINS",array(
    'plugin-1/plugin-1.php',
    'plugin-2/plugin-2.php',
    ...
    'plugin-n/plugin-n.php'
) );

 

You will be able to disable plugins by simply commenting on the related lines of the array. If you have dozen of plugins, this method will be the fastest way to disable plugins without accessing the backend.

To be able to unload the current theme FDP will suggest you add this line in wp-config.php:

 

define( "FDP_EMERGENCY_ADMIN_THEME_OFF",true );


If you still don’t have Freesoul Deactivate Plugins, of course, you will not be able to install it from the page of plugins, because your backend will not load. But no worries, you can take advantage of FDP even in this kind of situation.
In this case, here are the steps you should follow:

  • Download Freesoul Deactivate Plugins
  • Unzip the package
  • Transfer via FTP the plugin folder to the folder wp-content/plugins
  • Copy the file wp-content/plugins/freesoul-deactivate-plugins/eos-deactivate-plugins.php to wp-content/mu-plugins. If the folder wp-content/mu-plugins doesn’t exist, create it before transferring the file.

Now you are ready to follow the steps to be guided by FDP to find out the root cause of the issue.

This procedure is intended for all those cases when you can’t access the backend. Of course, if you are able to access the FDP settings page “Backend Singles”, you will be able to use the usual FDP features to preview the pages disabling specific plugins and the theme, but you can always access the emergency mode to get also the guided steps.

In some cases, even the emergency mode will not work.

If this happens it means neither the theme nor the plugins were the cause of the issue.

In this case, follow these steps:

  • Make a backup and then delete all the files that you find in wp-content/mu-plugins, and also these files if you find them in the folder wp-content:
    • ‘advanced-cache.php’,
    • ‘db.php’,
    • ‘db-error.php’,
    • ‘install.php’,
    • ‘maintenance.php’,
    • ‘object-cache.php’,
    • ‘php-error.php’,
    • ‘fatal-error-handler.php’

    Be careful, before deleting any file, save that file to a safe place, to be ready to restore it after the troubleshoot.

  • Check the .htaccess file
  • If you still have the issue, and the .htaccess file is ok, update the core of WordPress via FTP