If you have problems with your website and need to find out what errors are causing it, the built-in method with WordPress is to use the WP_DEBUG setting.
When this feature is turned on, all errors are written to a text file that you can open and get more details from about what is causing the problem.
Keep in mind, this file can contain sensitive data about your website or server, so you should not leave this feature turned on all the time, only when fixing errors.
How to enable WP_DEBUG
Open the file wp-config.php (usually found in the root of your website) and make sure the following settings are set up, and if they do not exist add them to the file:
ini_set('display_errors','Off'); define('WP_DEBUG', true); define('WP_DEBUG_LOG', true); define('WP_DEBUG_DISPLAY', false);
Once you have saved the changes you can go back to your website and try the same again, this time all errors should be written to the debug file, usually found in the folder /wp-content/debug.log
Remember, once you have finished debugging, turn off the debugging again by setting “WP_DEBUG” to “false”. You should also remove the debug.log file or use WP Security Ninja to block access to this file.