*/5 * * * * runs a job every five minutes. The */5 in the minute field is a step: take every fifth value of the range 0-59. The cron parser describes it as “Every 5 minutes” and expands the field to 0,5,10,15,20,25,30,35,40,45,50,55. The next runs are always on a multiple of five on the clock:
11:25 11:30 11:35 11:40 11:45 ...
The step operator
A step is written range/step:
| Field | Meaning |
|---|---|
*/5 |
from the start of the field to its end, every 5th value |
0-30/5 |
every 5th value between 0 and 30: 0, 5, 10, 15, 20, 25, 30 |
2-59/5 |
start at 2, every 5th value: 2, 7, 12, …, 57 |
It works in any field. 0 */2 * * * is every second hour, on the hour, and 0 0 */3 * * is every third day of the month (the 1st, 4th, 7th and so on), not “every 72 hours”.
Where the step breaks
A step counts from the start of the field, not from the previous run. So it only gives an even rhythm when the step divides the field’s size. Minutes have 60 values, so 2, 3, 4, 5, 6, 10, 12, 15, 20 and 30 are fine. Anything else gives an uneven gap:
*/7 → minutes 0, 7, 14, 21, 28, 35, 42, 49, 56 — then 0 again, 4 minutes later
Run */7 * * * * through the parser and you can see a gap of 4 minutes at each hour. The same thing happens with hours: 0 */5 * * * gives 0, 5, 10, 15 and 20 o’clock, and then the 0 o’clock of the next day, a gap of 4 hours. If you really need “every 7 minutes”, cron is the wrong tool: use a systemd timer, or have the job check the time since its last run.
Why the offset is useful
Many jobs start at minute 0, 5, 10, so the servers behind an API or a database get a burst at the same moment. If you have a choice, start at an odd minute:
2-59/5 * * * * /usr/local/bin/sync.sh >> /var/log/sync.log 2>&1
That is “every 5 minutes, starting at minute 2”. It avoids the common peaks at :00 and :30 without changing the frequency.
Checklist
- The job must finish well inside 5 minutes, or protect it with
flockas shown in every minute. - Use absolute paths and redirect the output; cron’s environment is minimal.
- The schedule uses the server’s time zone, which is often UTC. It does not matter for “every 5 minutes”, but it does for anything tied to the time of day.
For a slower pace, see every 15 minutes and every 6 hours. To assemble an expression by clicking, use the cron builder.
Frequently asked questions
What does */5 mean in cron?
Every fifth value of the field, counted from its start. In the minute field that is 0, 5, 10 and so on up to 55. The slash is the step operator, and it works in every field.
Is */5 the same as 0-59/5 and 0,5,10,15,20,25,30,35,40,45,50,55?
Yes, all three expand to the same twelve minutes. The star form is the shortest and the easiest to read.
Why does */7 not run every 7 minutes?
The step restarts at the beginning of each hour. */7 gives minutes 0, 7, 14 and so on to 56, then the hour changes and the next run is minute 0, only 4 minutes later. Cron can only keep an even gap when the step divides 60.
How do I run every 5 minutes but not on the hour, at minute 2, 7, 12, ...?
Give the range a start: 2-59/5 * * * *. It runs at minutes 2, 7, 12 and so on up to 57.
More in this reference
- Cron daily at midnight (0 0 * * *): @daily, time zones and a better hour
- Cron every 6 hours (0 */6 * * *): steps in the hour field
- Cron every 15 minutes (*/15 * * * *): quarter hours and staggered starts
- Cron every hour (0 * * * *): @hourly, and the mistake of * 0 * * *
- Cron every minute (* * * * *): how it works and the traps
- Cron every Monday at 9 AM (0 9 * * 1) and the day-of-month OR trap
- Cron on the first day of the month (0 0 1 * *): @monthly and its limits
- Cron on the last day of the month: why there is no L, and three working solutions
- Cron on weekdays at 9 AM (0 9 * * 1-5): Monday to Friday