Cron syntax in 30 seconds
A standard cron expression has five fields: minute hour day-of-month month day-of-week.
*every value ·5exactly 5 ·1-5a range ·1,15a list ·*/15every 15th- Months can be
JAN–DEC, daysSUN–SAT. Sunday is0or7. @hourly,@daily,@weekly,@monthly,@yearlyand@rebootare shortcuts.- A sixth field at the start means seconds (node-cron, Spring).
L= last day,5L= last Friday,1#2= second Monday.
The gotcha that surprises everyone
If you restrict both day-of-month and day-of-week, classic cron runs when either matches. 0 0 13 * 5 runs on every 13th and every Friday — not only on Friday the 13th. The explainer warns you when this applies.
Frequently asked questions
Which time zone does my cron job use?
The server's — usually UTC on cloud servers, GitHub Actions, Vercel and AWS. Switch the list to UTC to see when it really runs, with your local time underneath.
Does this work for Quartz expressions?
Mostly: 6 and 7-field schedules, ?, L and # are understood. One difference: Quartz numbers weekdays 1–7 starting Sunday, while this follows crontab (0–6). Use day names like MON to avoid confusion.
Why does GitHub Actions run my schedule late?
Scheduled workflows run in UTC, can't run more often than every 5 minutes, and are delayed when GitHub is busy — especially at the top of the hour. Pick an odd minute like 17 instead of 0.