The closest cron expression for every other day is 0 0 */2 * *, but the step restarts on the 1st of every month. See when it actually runs, and the one-line crontab that makes the spacing exact.
0minute0hour*/2day*month*weekday*/2 isn't really every 2 days
The day-of-month field restarts on the 1st of every month, so the last run of a month is followed by a run on the 1st — anywhere from 1 to 2 days later depending on the month. For an exact spacing, run daily and have the command skip days.
In Plain English
What your cron expression actually means.
Upcoming Executions
Preview the next 50 times this schedule will trigger.
About 0 0 */2 * *
0 0 */2 * * runs at midnight on the 1st, 3rd, 5th… of each month. Because the day-of-month step restarts on the 1st, a 31-day month ends with runs on the 31st and then the 1st — one day apart. For a spacing that survives month ends, run daily and let the command skip every other Unix day; the exact crontab below does that (the backslashes stop crontab from treating % as a newline).
Cron reads the five fields as minute hour day month weekday. For this schedule that breaks down as:
| Field | Position | Matches |
|---|---|---|
0 | minute | 0 |
0 | hour | 0 |
*/2 | day of month | 1, 3, 5, 7, 9, 11, … 31 (16 values) |
* | 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 12:00 AM, on day 1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, and 31 of the month 0 0 */2 * * /path/to/command
GitHub Actions workflow
# At 12:00 AM, on day 1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, and 31 of the month
# Note: GitHub Actions always runs schedules in UTC.
on:
schedule:
- cron: '0 0 */2 * *'Exact version for crontab
0 0 * * * [ $(expr $(date +\%s) / 86400 \% 2) -eq 0 ] && /path/to/command