Managed WooCommerce Stores Help

Access WordPress debug logs/PHP error logs on Managed WooCommerce Stores

Whether you're debugging an issue that bubbled up on your production site or troubleshooting an error on staging, debug logging is critical to maintaining a healthy WordPress site. In this article, we'll show you how to enable debug logging on your WordPress site so that you can squash those errors with ease.

Enable WordPress debug logging

To enable logging of any notices, warnings, or errors on your WordPress site, you'll first need to enable logging. Here's how to do it:

  1. Start by accessing your WordPress site's files over SFTP.

  2. Once connected, navigate to the root directory of your site and open the wp-config.php file in your preferred editor.

  3. Within your wp-config.php file, add or update your debugging settings to match the following:

    define('WP_DEBUG', true);
    define('WP_DEBUG_LOG', true);
    define('WP_DEBUG_DISPLAY', false);

    For more information on what each of these options do, see our WordPress debug settings reference.

  4. Finally, save the file. Once saved, WordPress debug logging has been activated.

Access WordPress debug logs

After you've enabled WordPress debug logging, accessing your logs are as simple as loading a URL in your browser. Simply visit the following URL, replacing with your site's domain:

Additional considerations

Only enable debugging when necessary

Aside from potential performance impacts that can occur when debugging is enabled, you'll also want to be aware that the logs are located within a publicly-accessible directory. For that reason, we recommend that you only enable debugging when actively debugging an issue or when on a restricted staging site.

WordPress debug logs are deleted when debugging is turned off

When finished debugging, simply turning the option off will automatially remove the WordPress debug logs. If you need to keep these logs, we recommend making a backup elsewhere before turning off debug mode.

Share this article