Connect with us


Handy Wordfence Constants



Handy Wordfence Constants

Wordfence is a commonly used plugin for site security that has a free version and a premium version. Wordfence includes a number of constants that can be added to the site’s wp-config.php file to turn off specific features and change some of the defaults.

MainWP has an easy-to-use code snippets plugin that will allow you to save these constants to any of the connected child sites into the child sites wp-config.php file.

The Wordfence scan results page will show up to 100 results by default this can be increased or decreased by using the following constant and setting the value as lower or higher.


If a scan has timed out and failed with the default being Wordfence checking for missing scan result messages every 5 minutes. You can increase the time to be longer at 10 minutes using this constant.


If the Wordfence Web Application Firewall (WAF) needed to be disabled if the protection level was set as being basic WordPress protection or if the wordfence-waf.php file is missing then the following constant can be used.

define('WFWAF_ENABLED', false);

Manage all your WordPress sites with the MainWP Dashboard

WordPress Management for Professionals

Are you ready to go Pro?

All MainWP Pro Extensions are available through one of our convenient bundled packages.

If you need to disable the file viewer on the scan results page then you can use the following constant.


If you need to be able to disable the live traffic feature on a site you can use this constant.


If you are using the Wordfence plugin on child sites but need to make specific changes or turn off specific features then it is possible using these handy constants with the MainWP Code Snippets extension. Wordfence also provided a number of other constants which can be used for other changes that made need to be made on any child sites using the Wordfence plugin.

Useful links

Source link

Continue Reading
Click to comment

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.