Search DevTools

Jump to any tool or page

Cron Expression Generator

Generate cron expressions, get a rich human-readable description, and preview upcoming run times in any timezone.

Builder

5 fields
Extra fields
Presets

A custom timezone overrides the dropdown above.

What this means

Asia/Kolkata
Expression

At 12:00 AM

Next 0 runs

No runs to show yet.

About cron expressions

A cron expression is a compact string used to schedule recurring jobs. It is a list of fields separated by spaces that tell a scheduler when to run a command. The most common form uses five fields:

  1. Minute (0–59)
  2. Hour (0–23)
  3. Day of month (1–31)
  4. Month (1–12 or JAN–DEC)
  5. Day of week (0–7 or SUN–SAT; both 0 and 7 often mean Sunday)

Some systems extend this with a seconds field (to the left) and/or a year field (to the right), giving 6 or 7 field formats. Cron fields support:

  • * — wildcard (every value)
  • 1-5 — range
  • */15 — step values
  • 1,2,3 — list
  • Special tokens like L, W, # in some implementations

Because implementations vary (CRON on Unix, Quartz scheduler, Kubernetes CronJob, etc.), always validate expressions against the scheduler you use. This generator uses cronstrue to produce readable descriptions and cron-parser to preview actual upcoming run times.

Notes

  • We use cronstrue for the human description (handles many cron features and localization).
  • Next-run times are computed with cron-parser. These are shown in ISO format for the selected timezone.

The description and next runs update automatically as you edit the builder or the expression field. For production systems, also validate expressions on the server-side with the same library or scheduler logic.

Developer Utilities

About Cron Expression Generator

Build and decode cron schedules, turning a field string into plain English and previewing the next run times. The pitfall that catches almost everyone is not the syntax but the semantics: when both day-of-month and day-of-week are restricted, standard cron combines them with OR rather than AND, so a schedule you read as "the 1st, if it is a Monday" actually fires on every 1st and every Monday.

Frequently asked questions

Why does 0 0 1 * MON run far more often than I intended?
Because of the day-of-month and day-of-week OR rule inherited from Vixie cron and codified in POSIX. When both fields are restricted — neither is * — the entry matches if either condition holds. So that expression fires on the 1st of every month and on every Monday, roughly 56 times a year rather than the one or two you expected. There is no portable way to express the AND. Encode the day-of-month constraint in cron and re-check the weekday inside the job itself.
Five fields or six? Which dialect am I writing?
Classic Unix cron takes five fields: minute, hour, day-of-month, month, day-of-week. Quartz and Spring's scheduler prepend a seconds field for six, and Quartz also appends an optional year for seven. Copy a Quartz expression into crontab and every field shifts by one, so 0 0 12 * * ? becomes a nonsensical schedule rather than a silent no-op. Quartz additionally requires ? in exactly one of the day fields, which plain cron rejects outright.
What happens to a 2am job when the clocks change?
On the spring-forward night, 02:00 to 02:59 local time does not exist, so a job scheduled then is skipped entirely. On the autumn-back night, that hour occurs twice, so a naive scheduler runs the job twice. Vixie cron mitigates this — wall-clock jobs skipped by a forward jump run once immediately afterwards, and it suppresses duplicates on the backward jump — but many cloud schedulers do not. Schedule anything sensitive outside 01:00 to 03:00 local, or run the daemon in UTC.
How do step, range and list values interact?
A step applies to the range preceding it, so */15 in the minute field means every 15 minutes starting at 0, while 5-59/15 means minute 5, 20, 35 and 50. A bare */7 in a field with 60 values does not divide evenly: it yields 0, 7, ... 56, then jumps back to 0 at the top of the hour, giving a four-minute gap. Lists combine as unions, and 0 9-17/2 * * 1-5 reads as every second hour from 09:00 to 17:00 on weekdays.
Are day-of-week 0 and 7 both Sunday, and what about month and day names?
In most implementations yes — 0 and 7 both denote Sunday, a compatibility concession — but Quartz numbers 1 as Sunday through 7 as Saturday, so a Quartz 5 is Thursday whereas a Unix 5 is Friday. Three-letter names such as MON and JAN are accepted by Vixie cron and Quartz, are case-insensitive, and are usually clearer. However, names cannot be used with steps in some parsers, and ranges crossing the year boundary such as NOV-FEB are not universally supported.