Loading...

Knowledge Base
Up to 75% off on hosting for WordPress websites and online stores

How to Set Up Cron Jobs in Account Manager

Important: You need to know Linux commands well before using cron jobs effectively. Please check your script with your hosting administrator before adding a cron job.

Cron Jobs is an automation tool. It allows you to automate specific commands or scripts on your site. You could set a command or script to run at a particular time every day, week, etc. (for example, set a cron job to delete temporary files weekly to free up disk space).

This guide will provide instructions on how to create, edit, or delete a Cron Job in Account Manager.

How to Create a Cron Job

  1. Log in to your Bluehost Account Manager.
  2. Click Websites on the left side of the navigation menu.
    am-websites-tab
  3. You can also click on the Hosting tab.
    bh-hosting

    Locate the hosting package you need to manage, and click its MANAGE button.

    am-hosting-manage-button
  4. On the website management page, locate the website you need to manage and click its SETTINGS button.
    am-websites-tab-settings-button
  5. Once you're in the website settings, click the Advanced tab, locate the Cron Jobs tile, and click Manage.
    advanced-settings-cron-jobs
  6. On the Cron Job Manager page, click the Add Cron button.
    cron-job-manager-add-cron
  7. You will then see your cron job scheduling options:
    • Common Settings– You can use this drop-down list to populate all but the last fields.
    • Minute – The minute setting for the cron job.
    • Hour – The hour setting for the cron job.
    • Day – The day setting for the cron job.
    • Month – The month setting for the cron job.
    • Weekday – The weekday setting for the cron job.
    • Command – The cron job command to execute. If you want to execute a script, it would look similar to the command below.
    /usr/local/bin/php -c /home/username/public_html/myscript.php
  8. Set the frequency of your Cron Job using the drop-down box for each setting, or use the Common Settings to choose from a list of regularly used intervals. Common Settings include every 15 minutes to once a year.
    add-a-cron-drop-down
  9. Enter the desired command and click Add.
    add-cron-job-pop-up-add

You have successfully created a Cron Job to execute a file at a specific time and date with the desired repetition.

How to View Existing Cron Jobs

The Current Cron Jobs section shows your existing cron jobs, allowing you to edit or delete them.
current-cron-jobs-tile

How to Edit a Cron Job

To edit a cron job, perform the following steps:

  1. Locate the cron job you wish to edit and click the 3 vertical dots icon.
    actions-option-cron-job
  2. Select Edit.
    am-edit-cron-job
  3. Once you're done updating your cron job, click on the Update button.
    edit-cron-job-update

How to Delete a Cron Job

To delete a cron job, perform the following steps:

  1. Find the cron job you want to remove and click on the 3 vertical dots icon.
  2. Click Delete.
    cron-job-delete
  3. On the pop-up window, then click Delete to confirm.
    delete-cron-job-confirm

The edit panel has fewer common settings, so if you are having trouble getting the correct interval, copy the command, delete the Cron Job, and recreate it using the Add Cron button.

Summary

Learn how to use Cron Jobs in Account Manager to automate specific scripts or commands on your website. With Cron Jobs, you can easily schedule a command or script to run at a particular time, day, or week, saving you time and effort. Our guide has step-by-step instructions on how to create, edit, or delete a Cron Job. Also, know the steps to view existing Cron Jobs and edit them if needed. However, it's crucial to learn Linux commands well before using Cron Jobs effectively, and it's always a good idea to check the script with your hosting administrator before using Cron Jobs.

If you need further assistance, feel free to contact us via Chat or Phone:

  • Chat Support - While on our website, you should see a CHAT bubble in the bottom right-hand corner of the page. Click anywhere on the bubble to begin a chat session.
  • Phone Support -
    • US: 888-401-4678
    • International: +1 801-765-9400

You may also refer to our Knowledge Base articles to help answer common questions and guide you through various setup, configuration, and troubleshooting steps.

Did you find this article helpful?

 
* Your feedback is too short

Loading...