How do I manage debugging in WordPress?

If you have problems with your WordPress site, activating debugging can help you find out what is wrong. When debugging is active, errors will be shown on the page where they occur.

In addition, you can use debug logging to log all errors to a file. However, this file is public by default , so we recommend using this feature with caution.

Note: Normally, debugging is used for development purposes only. Make sure to deactivate it after you have completed troubleshooting, as the error messages can give hackers information about vulnerabilities on your site.

  • How to manage debug mode
  • How to manage debug logging

How to manage debug mode

  1. Log in to your one.com Control Panel.
  2. In the menu on the left, go to Hosting settings and click File Manager
    You can also access your File Manager via the link https://filemanager.one.com
  3. Navigate to the directory where you installed WordPress.
  4. Click on the file wp-config.php to open it in the editor.
  5. Scroll down to:

define('WP_DEBUG', false);

  1. Change this to:

define('WP_DEBUG', true);

  1. Click Save at the top of the screen.
  2. After you don't need debugging any more, deactivate it by changing the line back to how it was in Step 5, and click Save.

Tip: We recommend that you copy the code exactly as shown above; an extra space or wrong character can affect your whole site.

Screenshot of the wp-config.php file in File Manager, showing where to activate debugging.

Did you know? 
If you’re facing error messages that you can’t resolve on your own – even with the help of our guides and support – or don't have time to fix them, our WP Troubleshooting service can help.

Use the contact form for Premium Care to get details, pricing, and priority assistance.

How to manage debug logging

If debug logging is active, all errors on your WordPress site will be logged to a file which is located in a public folder by default.

While this feature log can help with finding and fixing errors, a public error log can compromise your website's security, as it could include information which hackers could exploit. Therefore, we do not recommend activating this feature on a published site. If you need to use it, we recommend that you make your debug log private, or deactivate it and remove the error log from your site's public folder when you don't need it anymore.

Activate debug logging

Note: Debug logging can only be activated if debug mode is already enabled.

  1. Log in to your one.com Control Panel.
  2. In the menu on the left, go to Hosting settings and click File Manager
    You can also access your File Manager via the link https://filemanager.one.com
  3. Navigate to the directory where you installed WordPress.
  4. Click on the file wp-config.php to open it in the editor.
  5. Scroll down to:

define('WP_DEBUG', false);

  1. Change this to:

define('WP_DEBUG', true);

  1. Click Save at the top of the screen.
  2. After you don't need debugging any more, deactivate it by changing the line back to how it was in Step 5, and click Save.

Tip: We recommend that you copy the code exactly as shown above; an extra space or wrong character can affect your whole site.

Screenshot of the wp-config.php file in File Manager, showing where to activate debugging.

Related articles:

Was this article helpful?

Can’t find what you are looking for?

Start a chat

It's the quickest way to get in touch, every day of the year.

Give us a call

Available on weekdays from 10am to 2pm (UTC).