Cron on Monday, Wednesday and Friday: 0 0 * * 1,3,5
0 0 * * 1,3,5 runs at midnight on Monday, Wednesday and Friday, three times a week and about 156 times a year.
At a glance
- Expression
- 0 0 * * 1,3,5
- Fires
- 3 times a week, about 156 times a year.
- Restricted fields
- Day of week restricted to three values. Minute and hour pinned, day of month and month open.
- Equivalent macro
- None.
- Days matched
- Monday (1), Wednesday (3), Friday (5).
- Gap pattern
- Two days, two days, then three days across the weekend.
In detail
Every other weekday is a natural human schedule and an awkward cron one, because the week has seven days and the pattern only applies to five of them. A step will not do it: 1-5/2 happens to give 1, 3 and 5 here, but that is because the range excludes the weekend, and the same trick breaks the moment the days you want are not evenly spaced inside the range.
The comma list says exactly what is meant. Three values, three runs, no reasoning required by whoever reads it next. Names would normally read better, but this is the one set where they cannot be used: the parser screens each field for the Quartz characters L, W, # and ? before it resolves names, so a field containing WED is rejected. Write the numbers here.
The gaps are not equal. Monday to Wednesday is two days, Wednesday to Friday is two days, and Friday to Monday is three. A job that assumes a constant interval when computing its window will lose a day of data every weekend, which shows up as a Monday number that is consistently low.
Three times a week suits work that is too heavy for daily and too important for weekly: a full backup verification, a large report, a sync with a partner that publishes on their own cadence. It also keeps the failure recovery time down to two or three days, which is a lot more forgiving than a weekly schedule.
Examples
0 0 * * 1,3,50 0 * * MON,WED,FRIRejected. The field contains a W, which the parser screens for as a Quartz special character before it resolves day names.
0 0 * * 2,4Twice a week, with gaps of two days and five days.
Things that catch people out
- The Friday to Monday gap is three days, not two. Compute the window from dates rather than assuming a fixed lookback.
- 1-5/2 works here by luck. Use the list so the expression still says what you mean if the days change.
- WED cannot be used as a name in this parser, so this is one schedule that has to be written with numbers.
- Spaces inside the list split the field. 0 0 * * 1, 3, 5 is seven tokens and will not parse as intended.
Try it: Cron Expression Parser
Paste any five or six field expression to get a plain English description, a per field breakdown and the next run times in your local time.
Cron Expression Parser
LOCAL · Browser-OnlyParse cron expressions and see the next scheduled run times
Supports 5-field (minute hour day month weekday), 6-field (with seconds), named values (JAN, MON), and @macros (@daily, @hourly, ...)
Use the dropdowns below to build your cron expression visually, or type a custom value in each field.
Human-Readable Description
Every 5 minutes
Field Breakdown
| Field | Allowed | Value | Meaning |
|---|---|---|---|
| Minute | 0-59 | */5 | every 5 minute(s) |
| Hour | 0-23 | * | every hour |
| Day of Month | 1-31 | * | every day of month |
| Month | 1-12 | * | every month |
| Day of Week | 0-7 | * | every day of week |
Related cron expressions
All cron expressions →Cron twice a week: 0 9 * * 1,4
0 9 * * 1,4 runs at 09:00 on Monday and Thursday, twice a week. Which two days you pick decides whether the gaps are three and four days.
Cron every weekday: 0 0 * * 1-5
0 0 * * 1-5 runs at midnight Monday through Friday, five times a week. Day numbers, the MON-FRI alias, and why holidays still get a run.
The cron comma: listing several values in one field
A comma joins several values into one field, and each element can itself be a value, a range or a step. Spaces inside a list break the expression.
The cron day of week field: 0 to 7 with Sunday at both ends
The day of week field runs 0 to 7 with Sunday as both 0 and 7, and accepts SUN through SAT. Restricting it changes how the day of month field behaves.
Cron every 15 minutes on weekdays: */15 * * * 1-5
*/15 * * * 1-5 fires 96 times a weekday and 480 times a week. Combining a minute step with a weekday range, and how to add an hour window too.
Cron every 2 weeks: what cron cannot do and what to write
Cron has no fortnight. The two honest options are a semi monthly 1,15 schedule or a weekly job with a week parity test in the script.
Tools for this
- Cron Expression Parser Free online cron expression parser - parse cron expressions and see the next scheduled run times
- Crontab Generator Free online crontab generator - build cron expressions visually with an intuitive interface