How to set up cron jobs in cPanel

This article describes the way to use cPanel to configure cron jobs for your website. Using cron jobs, you’ll schedule commands to run at intervals that you specify.

What is a cron job?

A cron job is simply a task that you schedule to run automatically at specific intervals. For instance, if you want to back up a file every six hours, you’ll set this up easily using cPanel's cron jobs feature.

Adding a cron job

To add a cron job, follow these steps:

1. Log into cPanel.

2. In the ADVANCED section of the cPanel home screen, click Cron Jobs:


  

3. Under Cron Email, type the e-mail address where you want to receive notifications, and then click Update Email. Every time the cron job runs, the e-mail account receives a message.


"If you do not want to receive e-mail notifications for a particular cron job, you can append >/dev/null 2>&1 to the cron job command, which redirects all output to /dev/null."


4. Under Add New Cron Job, specify the interval for the command you want.


"If you choose an interval option under Common Settings, cPanel fills in the values automatically."


5. In the Command text box, type the command that you want to run.

6. Click Add New Cron Job. cPanel creates the cron job.


Editing a cron job

To edit a cron job, follow these steps:

1. Log into cPanel.

2. In the ADVANCED section of the cPanel home screen, click Cron Jobs:




3. Under Current Cron Jobs, click Edit for the cron job that you want to edit.

4. Make the changes that you want, and then click Edit Line.


Deleting a cron job

You can delete a cron job when you no longer want a command to run automatically.

To delete a cron job, follow these steps:

1. Log into cPanel.

2. In the ADVANCED section of the cPanel home screen, click Cron Jobs:

3. Under Current Cron Jobs, click Delete for the cron job that you want to delete.

4. Confirm that the cron job is the one that you want to delete, and then click Delete. cPanel deletes the cron job.

 

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

How can I change a database password on cPanel?

Changing MySQL database password via cPanel You can change your database’s password by...

How can I change my PHP version on cPanel?

Changing PHP version via cPanel Your Hosting Account's PHP version can be changed at any time,...

How can I create a new MySQL database in cPanel?

Creating a new MySQL database at Servers GATE using cPanel   You can easily create a new MySQL...

How can I locate my MySQL database details on cPanel?

Locating your MySQL database details via cPanel You can easily locate your MySQL databases...

How can I set up a redirect on cPanel?

Creating a redirect on cPanel Your hosting redirects can be easily managed with the assistance...