Cron First Day of the Year
Run a cron job on January 1st at midnight with 0 0 1 1 *. Complete field-by-field explanation, annual scheduling use cases, and platform support.
Cron Expression
0 0 1 1 *
Field Breakdown
| Field | Value | Meaning |
|---|---|---|
| Minute | 0 | At 0 |
| Hour | 0 | At 0 |
| Day of Month | 1 | At 1 |
| Month | 1 | At January |
| Day of Week | * | Every day of the week (Sun–Sat) |
Detailed Explanation
The cron expression 0 0 1 1 * schedules a task to run once per year, on January 1st at midnight.
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 very beginning of the new year.1(Day of Month): On the 1st day of the month only. Combined with the month field, this means January 1st.1(Month): January only. This restricts execution to the first month of the year.*(Day of Week): Every day of the week. No restriction on the day, so it runs regardless of which day January 1st falls on.
This means your task will execute exactly once per year at the stroke of midnight on New Year's Day. Annual jobs are used for year-end processing, annual report generation, license renewals, and data archival. Because this job runs so infrequently, consider adding robust logging, alerting, and retry mechanisms to ensure it completes successfully each year. Test it thoroughly before relying on it. 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
Commonly used for archiving the previous year's data to cold storage, resetting annual counters, and generating year-end summary reports.
Try It — Interactive Builder
Once a year, at midnight on January 1st
Next 10 Executions
Ctrl+Shift+C to copy expression