English

Cron Expression Parser — Explain and Next Runs

Cron expression explainer with 5/6 fields, next 5 runs and time zones

Runs in your browser · nothing is uploaded

Load an example

5-field form: minute hour day month weekday · 6-field form: second minute hour day month weekday

Every 5 minutes

In plain language

Every 5 minutes

Next 5 runs

    What it is

    A short cron expression like */5 * * * * is cryptic, even to the person who wrote it a few months ago. Enter one here and it is spelled out as a sentence, and the next five times it will actually run are calculated for the time zone you pick. The sentence comes from the open-source cronstrue library.

    How to use

    1. Type a cron expression or press an example button. Both the 5-field form and the 6-field form with seconds work.
    2. Read the meaning under “In plain language”.
    3. Choose a time zone; the next 5 runs are recalculated for it. The browser’s zone is the default.
    4. If you use an alias such as @daily, the standard expression it stands for is shown next to it.

    How it works

    • Field order: five fields are minute (0-59) hour (0-23) day (1-31) month (1-12) weekday (0-7); six fields add seconds (0-59) in front. Weekday 0 and 7 are both Sunday and 1 is Monday (Unix cron and Spring), which differs from Quartz, where 1 is Sunday.
    • A field can use *, a number, a range a-b, a list a,b and steps */n, a-b/n or a/n. Month and weekday also accept English abbreviations such as JAN and MON. In day and weekday, ? is treated like *.
    • Aliases: @yearly (0 0 1 1 *), @monthly (0 0 1 * *), @weekly (0 0 * * 0), @daily (0 0 * * *) and @hourly (0 * * * *).
    • When neither day-of-month nor day-of-week is *, a time runs if either of them matches.
    • Next runs are found by walking the clock of the selected zone field by field, looking at most 8 years ahead. A date that never comes, such as February 30, shows a message instead.
    • An invalid expression tells you which field and which value is the problem.

    Examples

    Expression Meaning
    */5 * * * * Every 5 minutes
    0 9 * * 1-5 At 09:00 on weekdays
    0 0 9 * * 1-5 Six fields: 09:00:00 on weekdays
    30 2 1 * * At 02:30 on the 1st of every month

    Notes

    • If the server runs in a different zone than your browser, the real run times differ too, so pick the zone the server uses when checking.
    • For dense expressions such as every minute or every second, the next five runs simply follow one another.

    FAQ

    What is the difference between 5 and 6 fields?

    Five fields are minute hour day month weekday; six fields put seconds first, giving second minute hour day month weekday. Linux crontab uses five, while Spring @Scheduled uses six. The tool tells them apart by field count. Weekdays are numbered as in Unix cron and Spring: 0 and 7 are Sunday, 1 is Monday. Quartz uses 1 = Sunday to 7 = Saturday, so a 6-field expression with ? and a numeric weekday shows a warning.

    Can it read Quartz expressions?

    A 6-field expression with weekdays written as names such as MON or FRI is read as is. Numeric weekdays are numbered differently (Quartz 1 = Sunday, this tool 0 and 7 = Sunday, 1 = Monday), so they would be one day off: use the names or subtract 1. If the expression is for Spring, which also accepts ?, the warning does not apply. The 7-field form with a year at the end and the L, W and # notations are not supported.

    What happens when both day-of-month and day-of-week are set?

    Classic cron rules apply, so a time runs if either one matches. For example 0 0 13 * 5 means midnight on the 13th of each month or on any Friday. If one of the two is *, only the other one is a condition.

    How are daylight-saving changes handled?

    Times are computed on the wall clock of the selected zone. A time skipped by a spring-forward jump does not run that day, and a time that occurs twice is run once, at its first occurrence. Real schedulers may behave differently, depending on their implementation.

    Are extensions like L, W and # supported?

    No. Numbers, ranges (-), lists (,), steps (/), * and ?, month and weekday abbreviations (JAN, MON) and the aliases @hourly, @daily, @weekly, @monthly and @yearly are understood. Anything else is reported as an error.

    Missing a tool?