Setting Up A Cron Job For WP Rocket On Siteground Hosting

If you want to create a real Cron job, first you need to disable WP Cron, so is not executed every time someone loads one of your pages. To disable it, open the wp-config.php file in your main WordPress folder and add the following line before the “/* That’s all, stop editing! Happy blogging. */” line:

SiteGround Site Tools menu with Cron Jobs selected

STEP 1

define(‘DISABLE_WP_CRON’, true);

STEP 2

Add a Cron job entry through your web hosting control panel.

See screen grabs below DEVS > Cron Jobs

You can set the job to run every 5 minutes.

5 minutes equals

*/5****

Please replace yourdomain.com with your actual domain:

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

DONE!

 

SiteGround Site Tools menu with Cron Jobs selected
SiteGround Create New Cron Job form with command and interval fields
SiteGround Manage Cron Jobs list showing a scheduled task
Setting up a cron job for WP Rocket on Siteground Hosting 1
Setting up a cron job for WP Rocket on Siteground Hosting 2
Setting up a cron job for WP Rocket on Siteground Hosting 3

Let’s Create Something Distinctive.

Tell us about your business, your ambitions and what comes next. We’ll discuss the right approach for your project.