Understand qué un cron expression actually ejecuta
Paste un cron expression, see el exact schedule campos y el siguiente fire times, y aprender el notations ese la mayoría a menudo surprise people.
- 1 Analizador de expresiones Cron →
Paste expressions like */15 * * * * or 0 9 * * 1-5. The tool breaks the expression into minute / hour / day-of-month / month / day-of-week fields and explains each in plain language.
- 2
Notation reminders: * means every value in the field; */5 means every 5th value starting from the field minimum; ranges (1-5) and lists (1,15) combine freely. The classic surprise: in standard cron, if both day-of-month and day-of-week are restricted (not *), a day matches when EITHER one matches — not both.
- 3 Generador de expresiones Cron →
Going the other way: describe a schedule and get the expression, useful for 6-field systems that add a seconds field.
- 4
Two portability warnings: some systems expect 6 or 7 fields (seconds, year) — verify your scheduler's dialect; cron fires in the server's local timezone, so a 9:00 expression runs at different UTC times on different hosts, and DST transitions can skip or duplicate runs.
Preguntas frecuentes
- Does cron handle daylight saving time?
- Cron evaluates wall-clock time, so runs can be skipped or duplicated around DST transitions. For interval-critical work, consider scheduling in UTC or using a monotonic timer.
- What is the difference between * and */5 in the minute field?
- * matches every minute. */5 matches minutes 0, 5, 10, ... 55 — every fifth minute starting at the field's minimum.
- Why doesn't my expression run on the expected day?
- If both day-of-month and day-of-week are restricted, standard cron ORs them. Use * in one of the two fields if you need AND semantics via a wrapper check.