Overview

If you are experiencing issues with a plugin or particular WordPress configuration, you can enable the detailed debug logs to capture detailed information to help determine the cause. This additional information may also be required for your plugin or theme developers upon request as well. This article will guide you through the process to enable.

Warning

Leaving debug logs on your system could lead to a potential security leak. Ensure the logs are deleted as soon as your debug session is complete.

Instructions

  1. Login to Plesk (or via the Conetix Control Panel) and select the domain you wish to enable WordPress debugging for.
  2. Select the WordPress Toolkit:
    how to enable wordpress debugging via the wordpress toolkit
  3. Click Check security:
    how to enable wordpress debugging via the wordpress toolkit
  4. To prevent accidental data leakage, we want to ensure that we Block access to potentially sensitive files:
    how to enable wordpress debugging via the wordpress toolkit
  5. Check and tick secure if there’s no green tick beside this item.
  6. Return to the WordPress Toolkit, then click on the settings button beside Debugging:
    how to enable wordpress debugging via the wordpress toolkit
  7. Enable WP_DEBUG and WP_DEBUG_LOG. If there are other options enabled (eg, WP_DEBUG_DISPLAY) we highly recommend disabling these:
    how to enable wordpress debugging via the wordpress toolkit
  8. Click OK and this will enable the additional debug logs. The slider within the WordPress Toolkit will also indicate that the debug logs are enabled:
    how to enable wordpress debugging via the wordpress toolkit
  9. To view the output of the debug logs, these can be either read via the Plesk File Manager or by using the Plesk Log Browser. To read via the Plesk Log Browser, return to the main Domains section, then select Logs:
    how to enable wordpress debugging via the wordpress toolkit
  10. At the top right of the Log Browser, click on the dropdown and select Add custom log:
    how to enable wordpress debugging via the wordpress toolkit
  11. Navigate to httpdocs/wp-content/ (or the equivalent wp-content if your directory structure is different) and select the debug.log file:
    how to enable wordpress debugging via the wordpress toolkit
  12. To view only the output of the debug.log file, go to the top right log file menu again and deselect all other logs. You should only have debug.log selected:
    how to enable wordpress debugging via the wordpress toolkit
  13. This will now display just the debug log output:
    how to enable wordpress debugging via the wordpress toolkit
  14. Once you’ve gathered the required logs, the next step is to disable the debug log again. Return to the WordPress Toolkit and click on the slider to disable.
  15. Finally, to ensure there’s no accidental leakage of data, you should delete the debug.log file completely. To do this, go to the Plesk File Manager:
    how to enable wordpress debugging via the wordpress toolkit
  16. Navigate to httpdocs/wp-content/ (or the equivalent wp-content if your directory structure is different), then select debug.log and click Remove:
    how to enable wordpress debugging via the wordpress toolkit

Was this article helpful?

Related Articles