How to Disable/Enable WordPress Cron

You are here:

By default WordPress virtual cron is enabled. If you are not using any cron or plugin which requires this feature, it is recommended to disable WordPress cron. This will reduce the resource usage for your website and server. In this article, we will explain how to Disable/Enable WordPress cron.

How to Disable the WordPress cron

To disable WordPress cron job system, You just need to add one line as follow in your wp-config.php file. This file should be available in the root of your WordPres installation. Find the following line in your wp-config.php:

define('DB_COLLATE', '');

Add the following line after the above line:

define('DISABLE_WP_CRON', true);

How to Enable the WordPress Cron

To enable the WordPress cron again, you just need to set false tag for DISABLE_WP_CRON as follow:

define('DISABLE_WP_CRON', false);

If you have cPanel or other hosting control panel, you can modify wp-config.php file using file manager.

If you are not using WordPress cron feature, you should still call wp-cron.php on a regular interval (i.e. once in an hour). This cron is useful to check for WordPress updates, plugins update, theme updates. Also, if you are using backup plugin, you will require to execute cron task.

If you are using cPanel, you can set a cron job from your cPanel by following the below steps:

[1] Login to your cPanel control panel.

[2] Go to “Cron Jobs“.

cPanel cron jobs

[3] Set your cron time from or you can adjust custom value and set the following command:

wget -q -O - http://yourwebsite.com/wp-cron.php?doing_wp_cron >/dev/null 2>&1

Make sure that you replace yourwebsite.com with your exact WordPress site URL.

WordPress cron command

This will execute your WordPress cron job on regular interval.

Last Updated On August 13, 2018

Leave a Reply

Your email address will not be published. Required fields are marked *

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