Skip to content
Hosting and dashboard

Schedule automated tasks (cron jobs)

Have a command run on its own every so often, without touching the terminal.

A cron job runs a command on a schedule: for example WordPress's cron, sending emails or cleaning up a store. You'll find it in your hosting's Cron jobs tab, if your plan includes it.

  1. In your hosting, open Cron jobs.
  2. Under Add a cron job, choose the Frequency: every 5 minutes, every hour, every day at 3:00 AM or every week (Sunday 3:00 AM). For anything else, choose Custom… and type the Cron expression.
  3. In Command, type what should run, on a single line.
  4. Click Add cron job.

Examples

Command for a PHP script
/usr/local/bin/php /home/username/public_html/cron.php
Expression: every day at 4:30 AM
30 4 * * *

Replace username with your account username (shown in the Overview). A cron expression has five fields: minute, hour, day, month and day of the week.

Don't schedule heavy tasks every minute: they use your plan's resources and can slow down your website.

Ask the assistant

Still have a question about this? Ask the assistant.

Was this article helpful?

Related articles