Cron Every Other Day

Schedule a cron job every other day at midnight using 0 0 */2 * *. Full field-by-field explanation, alternate-day scheduling tips, and use cases.

Cron Expression

0 0 */2 * *

Field Breakdown

FieldValueMeaning
Minute0At 0
Hour0At 0
Day of Month*/2Every 2nd day of month
Month*Every month (1–12)
Day of Week*Every day of the week (Sun–Sat)

Detailed Explanation

The cron expression 0 0 */2 * * schedules a task to run every other day at midnight, on odd-numbered days of the month.

Field-by-field breakdown:

  • 0 (Minute): At minute 0. The task fires at the start of the hour.
  • 0 (Hour): At hour 0 (midnight). The task runs at the beginning of each matching day.
  • */2 (Day of Month): Every 2nd day, starting from day 1. The step value /2 triggers execution on days 1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, and 31.
  • * (Month): Every month from January through December. No restriction on the month.
  • * (Day of Week): Every day of the week. No restriction on the day of the week.

This means your task will execute approximately 15-16 times per month, every other day. Note that because months have varying lengths, the gap between the last day of one month and the first day of the next may not always be exactly two days. For example, after January 31st the next run is February 1st, creating back-to-back executions. Despite this edge case, this schedule is useful for tasks needing regular but not daily execution. This expression is supported by standard cron on Linux/macOS, as well as cloud services like AWS CloudWatch, Google Cloud Scheduler, and GitHub Actions.

Use Case

Useful for running database cleanup scripts that purge expired sessions and temporary records every other day to balance freshness and performance.

Try It — Interactive Builder

Every 2 days at midnight

**/5*/10*/15*/300
**/2*/3*/6*/120
*1151,15*/2
*11,4,7,101,7
*1-50,615

Next 10 Executions

1.Fri, Mar 13, 2026, 12:00 AM
2.Sun, Mar 15, 2026, 12:00 AM
3.Tue, Mar 17, 2026, 12:00 AM
4.Thu, Mar 19, 2026, 12:00 AM
5.Sat, Mar 21, 2026, 12:00 AM
6.Mon, Mar 23, 2026, 12:00 AM
7.Wed, Mar 25, 2026, 12:00 AM
8.Fri, Mar 27, 2026, 12:00 AM
9.Sun, Mar 29, 2026, 12:00 AM
10.Tue, Mar 31, 2026, 12:00 AM

Ctrl+Shift+C to copy expression

Customize this expression