How cron expressions work
A standard cron expression has five fields separated by spaces: minute hour day-of-month month day-of-week. Each field accepts a single value (5), a list (1,15,30), a range (9-17), a step (*/10) or a range with a step (0-30/5). An asterisk means "every value".
| Field | Allowed values | Example |
|---|---|---|
| Minute | 0–59 | */15 = every 15 minutes |
| Hour | 0–23 | 9-17 = 09:00 through 17:59 |
| Day of month | 1–31 | 1 = first day |
| Month | 1–12 or JAN–DEC | 1,7 = January and July |
| Day of week | 0–7 or SUN–SAT (0 and 7 are Sunday) | 1-5 = Monday to Friday |
The day-of-month vs day-of-week gotcha
If you restrict both day-of-month and day-of-week, most cron implementations run the job when either matches, not both. So 0 9 1 * 1 runs at 09:00 on the 1st of every month and every Monday. This tool follows that classic Vixie-cron behaviour.
Common expressions
0 * * * *: every hour on the hour0 0 * * *: daily at midnight (same as@daily)30 2 * * 0: Sundays at 02:300 9-17/2 * * 1-5: every two hours from 09:00 to 17:00 on weekdays0 0 1 */3 *: the first day of every quarter
Time zones
Cron runs in the time zone of the machine or scheduler: often UTC on servers and cloud schedulers. Switch the selector above to UTC to see exactly when a server-side job will fire, and remember daylight-saving changes can skip or repeat local times.