5-Field vs 6-Field Cron: What Changes?
Short answer. A five-field cron expression sets minute, hour, day of month, month and day of week. A six-field expression adds seconds in front, so each later field moves one position right. Paste a five-field line into a six-field scheduler unchanged and the job runs at the wrong time, or the scheduler rejects the line.
Updated 2026-10-28
Both formats describe the same idea: match the current time against a set of fields, and run the command when every field matches. The difference is where the matching starts. Field count is the first thing to check when a schedule looks shifted by a few hours or refuses to save.
The five standard fields
The POSIX crontab format is the reference. The manual page on this machine lists exactly five time fields and their allowed values:
| Field | Allowed values, as printed by man 5 crontab |
|---|---|
| Minute | 0 to 59 |
| Hour | 0 to 23 |
| Day of month | 1 to 31 |
| Month | 1 to 12, or the first three letters of the name |
| Day of week | 0-7 (0 or 7 is Sun, or use names) |
The same page defines the operators: an asterisk stands for first to last, a hyphen gives an inclusive range such as 8-11, a comma gives a list such as 0-4,8-12, and a slash gives a step, so */2 in the hour field means every second hour. Month and day of week accept the first three letters of the name.
Where the sixth field goes
Schedulers that support seconds put the seconds field first, not last. Spring's @Scheduled cron support, Quartz, and AWS EventBridge all document a six-field expression that starts with seconds, which shifts every other field one position to the right:
| Position | Five fields | Six fields |
|---|---|---|
| 1 | minute | second |
| 2 | hour | minute |
| 3 | day of month | hour |
| 4 | month | day of month |
| 5 | day of week | month |
| 6 | - | day of week |
Two readings of almost the same line
Take the schedule "every day at 02:30". The five-field form is:
30 2 * * * minute 30, hour 2, every day
In a six-field scheduler the same intent needs a seconds value in front, or the fields are read one place to the left and the line means "every minute of hours 30 and 2":
0 30 2 * * * second 0, minute 30, hour 2, every day
That misreading is the usual reason a migrated schedule runs 24 times an hour at two in the morning instead of once. Check the field count before you check anything else.
Rules that do not change
- An asterisk still means "first to last" in that position, whatever the position is called.
- Ranges, lists and steps work the same way in both formats.
- Day of week still accepts
0or7for Sunday in the POSIX format, and both mean the same day. - In a five-field crontab, day of month and day of week are combined with OR, not AND, when both are restricted. A line with both fields set can run on more days than you expect.
- Month numbering is 1 to 12 in the POSIX format. Schedulers that use zero-based months exist, so convert the numbers when you move a line between systems.
Checklist before you paste a cron line
- Count the fields. Five means minute first, six means second first.
- Read the line aloud field by field and confirm the rightmost field before the command is day of week.
- Confirm Sunday is 0 in your scheduler, or write Sunday as a name.
- Confirm the month numbering is 1 to 12, or convert it.
- Run the expression through a builder that prints the next fire times, and compare them with the wall clock you expect.
InvokeBot's cron expression builder prints the next run times for an expression, and the cron to webhook scheduler turns the same schedule into a webhook trigger. On macOS, note that man 5 crontab records that cron has been absorbed into launchd, so a plist schedule on that platform has its own key names rather than cron fields.
Frequently Asked Questions
Does a six-field expression always start with seconds?
Check the documentation of the scheduler you are using rather than assuming. Seconds-first is the common convention for systems that add a sixth field, but a scheduler that extends the format at the end instead would place the extra field differently. If the documentation does not say, test one line and read the next fire times.
Why does "0 0 * * 0" run on Sunday?
Because the day of week field accepts 0 for Sunday in the POSIX format, and the manual page lists 0 or 7 as two ways to write the same day. The first two zeros in that line are minute and hour, midnight, and the final zero is day of week.
What happens if I drop the seconds field from a six-field line?
The remaining five fields are read as minute, hour, day of month, month and day of week. A line built for a seconds-first scheduler loses its last field and the day of week value becomes the month value, which usually produces a validation error or a schedule that fires on the wrong days. Convert the line instead of truncating it.