Skip to main content
TrustServers Knowledge Base

Tip: Start typing to get instant search results.

Table of Contents

Activation of WP_DEBUG in WordPress (dedicated servers)

In WordPress, when hosted on dedicated servers, you have the ability to enable or disable WordPress DEBUG logging. However, you do not have the ability to specify which file the logging will be written to for security reasons (logging data is written to a predefined file outside of public_html/).

  1. Locate and open the wp-config.php file

    Using FTP or SSH, find the wp-config.php file located in the root (in the public_html folder) of your WordPress installation.

  2. Enable WordPress Debug

    Add or modify the following lines inside wp-config.php to enable error logging:

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

    If you want to disable debugging, change the value to false for all variables.

    The WP_DEBUG_DISPLAY variable, if set to true, displays debug messages in the browser (on your website).

⚠️ Note: On dedicated servers specifically, the wp-content/debug.log file does not work. However, you will find the log in a file in the logs/ subdirectory of your home directory.

Was this article helpful?
Please Share Your Feedback
Πώς μπορεί να βελτιωθεί το άρθρο;
Tags:
Privacy Overview

This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.