Cheat Sheets · Cron Cheat Sheet · Cron First Day of the Month — Crontab Example
Cron First Day of the Month — Crontab Example
0 0 1 * *
Runs at 00:00 (midnight) on the 1st of every month.
Field by field
| Field | Value | Meaning |
|---|---|---|
Minute | 0 | At minute 0 |
Hour | 0 | At midnight |
Day of month | 1 | The 1st of the month |
Month | * | Every month |
Day of week | * | Any day of the week |
Month-start jobs (invoicing, cleanup, reporting cycles) restrict day-of-month to 1 and leave day-of-week wildcarded. Leaving day-of-week as * matters — the union trap means adding a day-of-week restriction would fire on extra days.
The @monthly shorthand is exactly this expression.
0 0 1 * * /usr/local/bin/monthly-invoice.sh
Related schedules
FAQ
Is there an @monthly shorthand?
Yes — @monthly equals 0 0 1 * * *… more precisely 0 0 1 * *: midnight on the 1st.
What if the 1st falls while the server is down?
The run is skipped for that month. If it must happen, have the job check its last success timestamp and catch up, or run nightly with an "is today the 1st?" guard.
Can I run at 6 PM on the 1st instead?
Set the hour field: 0 18 1 * * — minute 0, hour 18, day 1.
Stop memorizing — build it interactively
Try this schedule in the Cron EditorFull reference: Cron Cheat Sheet