No single cron expression runs exactly every 40 minutes: */40 * * * * fires at :00 and :40, then restarts on the hour. See the real run times, and the few crontab lines that make the spacing exact.
*/40minute*hour*day*month*weekday*/40 isn't really every 40 minutes
The minute field restarts every hour, so after :40 the next run is :00 — a 20-minute gap, not 40. Even alternatives: */2, */3, */4, */5, */6, */10, */12, */15, */20, */30.
In Plain English
What your cron expression actually means.
Upcoming Executions
Preview the next 50 times this schedule will trigger.
About */40 * * * *
*/40 * * * * is the closest single line, but it isn't every 40 minutes. The minute field restarts every hour, so this fires at :00 and :40 and then at :00 again — a 20-minute gap. Because 40 divides a whole day (1440 minutes), 2 lines together give an exact 40-minute rhythm, including across midnight — see the exact crontab below.
Cron reads the five fields as minute hour day month weekday. For this schedule that breaks down as:
| Field | Position | Matches |
|---|---|---|
*/40 | minute | 0, 40 |
* | hour | every hour |
* | day of month | every day |
* | month | every month |
* | day of week | every day of the week |
New to cron? Read the syntax reference or the FAQ.
Use it in crontab or GitHub Actions
The single line below is the closest cron gets, not the exact schedule (see above). A crontab runs in the server's local timezone; GitHub Actions always evaluates schedules in UTC. For Kubernetes, AWS EventBridge, or Vercel, use the export menu in the calculator above.
crontab
# At 0 and 40 minutes past the hour, every hour, every day */40 * * * * /path/to/command
GitHub Actions workflow
# At 0 and 40 minutes past the hour, every hour, every day
# Note: GitHub Actions always runs schedules in UTC.
on:
schedule:
- cron: '*/40 * * * *'Exact version for crontab
0,40 */2 * * * /path/to/command 20 1-23/2 * * * /path/to/command
GitHub Actions takes the same lines as separate - cron: entries under schedule.