ModernCalcs

Cron Expression Validator

Validate each field of a cron expression against its allowed range, see a plain-English description, and preview the next 5 run times.

Every 15 minutes, between 09:00 and 17:59, Monday through Friday
Minute
*/15
Hour
9-17
Day of Month
*
Month
*
Day of Week
1-5
Next 5 Runs
8/19/2026, 5:45:00 PM
8/20/2026, 9:00:00 AM
8/20/2026, 9:15:00 AM
8/20/2026, 9:30:00 AM
8/20/2026, 9:45:00 AM
Try an Example

Cron Expression Validator: Catch Scheduling Bugs Before They Ship

A single out-of-range digit in a cron expression can silently break a scheduled job — or worse, make it run every minute instead of once a day. Our validator checks each of the five fields against its valid range, explains exactly what went wrong, and shows you the next five times a valid schedule would actually fire.

Formula
minute hour day-of-month month day-of-week

Ranges: 0-59, 0-23, 1-31, 1-12, 0-7 (0 and 7 both mean Sunday).

Why Field-Level Validation Matters

A generic 'invalid cron string' error doesn't tell you which field is the problem. Our validator checks each of the five fields independently against its allowed range and reports the exact segment that failed — for example, flagging '70' in the minute field because valid minutes are 0-59.

Day-of-Month vs. Day-of-Week

One of the most common cron mistakes is misunderstanding how day-of-month and day-of-week interact. When both are restricted (not '*'), most cron implementations run the job if either condition is true, not both — so '0 0 15 * 1' runs on the 15th of every month and every Monday.

Reading Steps and Ranges Together

Expressions like */15 9-17 * * 1-5 combine a step (every 15 minutes) with a range (9am-5pm) and a list (Monday-Friday). Our validator parses each of these operators independently so you can see exactly which values a compound expression resolves to.

Practical Examples

Catching an Out-of-Range Hour

A common typo when writing schedules by hand.

  • 1.Input: 0 25 * * *
  • 2.Hour field error: Value 25 is out of bounds (0-23)
  • 3.Fix: 0 0 * * * for midnight

Validating a Business-Hours Job

Confirming a schedule does what you expect.

  • 1.Input: */15 9-17 * * 1-5
  • 2.All 5 fields valid
  • 3.Description: Every 15 minutes, between 09:00 and 17:59, Monday through Friday

Common Validation Errors

  • Out-of-range value: e.g. 61 in the minute field
  • Malformed range: e.g. 17-9 where start is greater than end
  • Wrong field count: fewer or more than 5 space-separated fields
  • Zero or negative step: e.g. */0

Cron Syntax Cheat Sheet

  • *: every value
  • ,: list, e.g. 1,15,30
  • -: range, e.g. 9-17
  • /: step, e.g. */5 or 9-17/2

Frequently Asked Questions

Why does my cron expression need exactly 5 fields?

Standard cron uses 5 fields: minute, hour, day-of-month, month, and day-of-week. Some systems (like some CI tools) support a 6th 'seconds' field, but the classic Unix cron format is always 5.

What's the valid range for each field?

Minute: 0-59, Hour: 0-23, Day of Month: 1-31, Month: 1-12, Day of Week: 0-7 (both 0 and 7 mean Sunday).

What does an asterisk (*) mean?

It means 'every value' for that field — for example, * in the hour field matches every hour.

How do ranges and steps work?

A range like 9-17 matches every value from 9 to 17. A step like */15 matches every 15th value starting from the field's minimum. You can combine them, e.g. 9-17/2.

Why is my Day of Month + Day of Week combination confusing?

In standard cron, when both fields are restricted (not *), most implementations treat them as an OR — the job runs if either the day-of-month OR the day-of-week matches, not both.

Does this tool run my cron job?

No. It only validates syntax and previews when the schedule would fire — it doesn't execute anything. Everything runs locally in your browser.

Why doesn't it show any upcoming runs?

If your expression targets a very rare combination (like day-of-month 31 in February), a valid next run might be more than a year away, which is outside this tool's preview window.

What's the difference between this and a cron builder?

A builder helps you construct a schedule from dropdowns. This validator instead takes an expression you already have and tells you exactly which field is wrong and why.