Cron syntax
┌──────── minute (0–59) │ ┌────── hour (0–23) │ │ ┌──── day of month (1–31) │ │ │ ┌── month (1–12 or JAN–DEC) │ │ │ │ ┌ day of week (0–7 or SUN–SAT, 0 and 7 are Sunday) * * * * *
| Symbol | Meaning | Example |
|---|---|---|
* | Every value | * * * * * every minute |
, | List | 0 9,17 * * * at 09:00 and 17:00 |
- | Range | 0 9 * * 1-5 weekdays at 09:00 |
/ | Step | */15 * * * * every 15 minutes |
Day of month and day of week together
When both day fields are set (not *), standard cron runs when either matches. 0 0 1 * 1 runs on the 1st of each month and every Monday, not only on Mondays that fall on the 1st.
Shortcuts
@yearly, @monthly, @weekly, @daily and @hourly are accepted and expanded.
Time zones
Cron runs in the time zone of the server or scheduler. Around daylight-saving changes, cron implementations differ for times that are skipped or repeated, so avoid scheduling jobs between 01:00 and 03:00 local time if they must run exactly once. Many cloud schedulers (GitHub Actions, AWS EventBridge, Kubernetes CronJobs by default) use UTC, so check the next runs in UTC as well as your own time zone.