Cron Expression Explainer
Runs in your browserPaste a cron expression to see what it actually means: a sentence, a field-by-field breakdown, and the next ten times it will run.
At 02:30 on Monday, Tuesday, Wednesday, Thursday and Friday
| Field | Value | Means |
|---|---|---|
| 1. minute | 30 | 30 |
| 2. hour | 2 | 02 |
| 3. day of month | * | Every day |
| 4. month | * | Every |
| 5. day of week | MON-FRI | Monday, Tuesday, Wednesday, Thursday and Friday |
Next 10 runs
How this one works
A cron expression is a set of fields, each saying which values of that unit a job may run on. Five fields is the classic crontab — minute, hour, day of month, month, day of week. Add a sixth at the front and it is seconds, the form Spring and Quartz use; the dialect is guessed from the shape of what you paste, and the picker overrules it.
The next runs are worked out in the zone you choose, using your browser's own time zone database, so daylight saving is handled properly: a reading that is skipped when clocks go forward, and one that happens twice when they go back, are both flagged in the list.
Two details catch people out. Sunday is 0 in crontab and Spring but 1 in Quartz, so the same digit means different days — the breakdown spells out the day names to make that obvious. And when both day fields are restricted, classic cron runs the job when either matches, not both; Quartz avoids the ambiguity by insisting on ? in one of them.
Questions
- Which special characters are supported?
- Ranges (1-5), steps (*/15 and 5/10), lists (1,15,30), names (MON, JAN), * and ?, plus L for the last day or last weekday, L-3 for three days before month end, 15W for the weekday nearest the 15th, and 6#3 for the third Friday. The @hourly, @daily, @weekly, @monthly and @yearly macros expand to their expressions.
- Why does my job not run on the day I expect?
- Check the day fields. In crontab, "0 0 1 * MON" runs on the 1st of the month AND on every Monday, because a restricted day-of-month and day-of-week are combined with OR. Set one of them to * (or ? in Quartz) if you want only the other.
- What happens at a daylight-saving change?
- It depends on the scheduler, so this page shows you which runs are affected rather than guessing. Vixie cron runs a job whose time was skipped once, shortly after the jump; a job in a repeated hour usually runs only once. Schedules that run every few minutes are unaffected either way.
- Is my expression sent anywhere?
- No. Parsing and the run times are computed in this tab, with no network requests at all. The URL keeps your expression so you can share a link, and that link only travels if you send it.