Skip to content

How to properly debug WordPress Errors and the White Screen of Death

saulhm / Pixabay

Sometimes when you activate a plugin there appears an error message like „cannot activate this plugin, there has been a fatal error“. Then at least you know it is a error with the plugin. But if you do have error reporting set to off in your hosting you will not even see this error. Another pretty common Situation is the most famous White Screen of death. A wordpress error that prevents you not only from seeing your website but also from entering the backend.

Usually the first steps to find the problems include these:

  • Check if a plugin is the problem:
    • Connect via FTP to your Server
    • Move all plugins one level up to temporarily disable them
      (simply move them from wp-content/plugins/ to wp-content/)
    • If a plugin is the culprit the website will now work again as expected
    • You can then move the plugins back one by one until you find the plugin that causes it to Crash
  • Check if your theme is the problem:
    • Move your theme folder one level up, to automatically enable the default theme (make sure you have one present)
      (simply move it from wp-content/themes/yourtheme to wp-content/yourtheme)
  • Check if the htccess file is the Problem
    • Simply rename it from .htaccess to _,htacces to temparily disable it
    • If your Website works again, enter your backend via /wp-admin and sae the permalinks Settings again to create a new .htaccess file

If These Basic steps did not work you still have chances to dig more into the Problem. Fortunately wordpress itself provides a whole kit of tools to help you hunt those naggy bugs and regain Access to your website or find the flaw that killed the system.

Simply add these lines to your wp-config.php file.

//Enable php error reporting
error_reporting(E_ALL); ini_set('display_errors', 1);

//Enable WP_DEBUG mode
define('WP_DEBUG', true);

//Optional: Enable Debug logging to the /wp-content/debug.log file
//define('WP_DEBUG_LOG', true);

//Disable display of errors and warnings 
//define('WP_DEBUG_DISPLAY', false);

//Optional: Use dev versions of core JS and CSS files (only needed if you are modifying these core files)
//define('SCRIPT_DEBUG', true);

Now the white screen will have more Information about what went wrong so you have a chance to repair it. Now when this error occurs again a debug file will be created in wp-content/debug.log. Have a look and get a clue how to fix whats broken. Just a hint: Most common is a conflict with functions names in your functions.php and a plugin. So always make sure you use unique function description.

Read more about debuggin wordpress on

Dieser Beitrag hat 0 Kommentare

Schreibe einen Kommentar

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert

An den Anfang scrollen