What it checks
Checks WP_DEBUG, WP_DEBUG_DISPLAY, debug.log, wp-config.php permissions and the built-in file editor.
Check ID: env.wp_config
WP_DEBUGandWP_DEBUG_DISPLAY.- Whether a debug log exists: the path in
WP_DEBUG_LOG, orwp-content/debug.log. - The permissions of
wp-config.php, in the WordPress folder or the folder above it (not on Windows servers). - Whether the theme and plugin file editor is available (
DISALLOW_FILE_EDITorDISALLOW_FILE_MODSis not set).
What a finding means
The titles, severities and explanations below are the ones shown on the Findings screen.
| Finding | Severity | Meaning |
|---|---|---|
Debug messages are shown to visitorswp_config.debug_display | High | WP_DEBUG is on and WP_DEBUG_DISPLAY is not off, so PHP notices and errors appear on pages and reveal file paths. |
WP_DEBUG is enabledwp_config.debug | Low | Debug mode is on. It is meant for development and can slow the site and fill the log. |
debug.log existswp_config.debug_log | Medium Low | A debug log is stored inside wp-content, where it may be downloadable. Logs can contain paths, queries and personal data. Medium: the log is inside wp-content. Low: the log is elsewhere. |
wp-config.php is world-writablewp_config.permissions_writable | Critical | wp-config.php has permissions …. Anyone on the server can change it. |
wp-config.php is readable by everyone on the serverwp_config.permissions_readable | Low | wp-config.php has permissions …. On shared servers other accounts may be able to read your database password. |
Theme and plugin file editor is enabledwp_config.file_edit | Low | Administrators can edit PHP files from the dashboard. A stolen admin account can then run arbitrary code. |
How to fix
The recommended action shown with each finding:
- Debug messages are shown to visitors
Set define( 'WP_DEBUG', false ) on production, or at least define( 'WP_DEBUG_DISPLAY', false ). - WP_DEBUG is enabled
Set define( 'WP_DEBUG', false ) on production. - debug.log exists
Delete the log when it is no longer needed, and set WP_DEBUG_LOG to a path outside the web root. - wp-config.php is world-writable, wp-config.php is readable by everyone on the server
Set the permissions to 400 or 440 (600/640 if your host requires write access). - Theme and plugin file editor is enabled
Add define( 'DISALLOW_FILE_EDIT', true ); to wp-config.php.
Related settings
- Settings → Checks → Enabled checks: switch “WordPress configuration” on or off.