Replace wp-cron with a cPanel cron job Print

  • wordpress
  • 0

To stop WordPress from executing wp-cron.php after every page visit, simply add this single line to the end of your wp-config.php file:

define('DISABLE_WP_CRON', 'true');

In the Advanced section of cPanel, click Cron jobs.

Locate "Add New Cron Job". The cPanel Cron jobs tool has a number of common schedules preset. To execute the command every every 30 mins, select Twice an hour from the Setting drop down. We recommend that you don't set the interval lower than 15-30 minutes.

Add the following command. Replace https://www.example.com with your site’s domain;

wget -q -O – https://example.com/wp-cron.php?doing_wp_cron >/dev/null 2>&1 :


Was this answer helpful?

« Back