Cron expression for every hour
0 * * * * runs once an hour, on the hour. The 0 is what makes it hourly: a star in its place would run the job every minute.
This tool runs in your browser. We never send what you type or paste to a server.
The expression
0 * * * * /path/to/commandThe expression has five fields, read left to right:
| Field | Value | Meaning here |
|---|---|---|
| Minute | 0 | at minute 0 only |
| Hour | * | every hour |
| Day of month | * | every day of the month |
| Month | * | every month |
| Day of week | * | every day of the week |
When it runs
Starting from Wed 2027-01-06 10:07 UTC, the next runs are:
Wed 2027-01-06 11:00
Wed 2027-01-06 12:00
Wed 2027-01-06 13:00
Wed 2027-01-06 14:00
Wed 2027-01-06 15:00
Wed 2027-01-06 16:00Cron uses the time zone of the machine or service that runs it. The explainer at the top of this page shows the next runs in your own time zone.
The mistake to avoid
0 * * * * once an hour 24 runs a day
* * * * * every minute 1,440 runs a day
* */1 * * * also every minute 1,440 runs a dayThe minute field decides how often the job runs within each matching hour. People write * */1 * * * meaning "every 1 hour" and get a job that runs sixty times as often as intended.
Variations
17 * * * * every hour at 17 minutes past
0 9-17 * * * every hour from 09:00 to 17:00
0 * * * 1-5 every hour on weekdays
@hourly the same as 0 * * * *Unless the job has to run exactly on the hour, pick another minute. A random one is as good as any, and it keeps your job away from everyone else's hourly jobs. On systems with /etc/cron.hourly/, scripts dropped in that directory are run once an hour by the system crontab.
Quartz adds a seconds field at the front, AWS adds a year at the end, and both need ? in one of the two day fields. See how the syntaxes differ.
The same schedule in other schedulers
| Scheduler | Expression |
|---|---|
| Unix cron, crontab | 0 * * * * or @hourly |
| Kubernetes CronJob | schedule: "0 * * * *" |
| GitHub Actions | - cron: '0 * * * *' |
| Quartz (Java, Spring) | 0 0 * * * ? |
| AWS EventBridge | cron(0 * * * ? *) |
Questions
What is the cron expression for every hour?
0 * * * *, which runs at minute 0 of every hour. Many cron versions also accept @hourly.
How do I run a cron job every hour at 30 minutes past?
30 * * * *. The first field is the minute within each hour.
Does @hourly work everywhere?
It works in Vixie cron and its descendants (cronie, the cron in Debian and Ubuntu) and in Kubernetes CronJobs. GitHub Actions, Quartz and AWS EventBridge do not accept it.