Home โบ Cron errors โบ Crontab
crontab error: bad minute
crontab: installing new crontab
"/tmp/crontab.xxxx":1: bad minute
errors in crontab file, can't install.Why this happens
The minute field only allows 0-59. Writing 60 for "every hour" is a common slip.
Wrong and right
60 * * * *Our parser says: min value 60 is out of range (0-59)
0 * * * *At minute 0. First runs after 1 Jan 2027 (UTC): Fri 01 Jan, 01:00, Fri 01 Jan, 02:00, Fri 01 Jan, 03:00, Fri 01 Jan, 04:00, Fri 01 Jan, 05:00
How to fix it
- Use 0 for the top of the hour.
- Use */N for intervals within the hour.
- Run crontab -l after saving to confirm the line was installed.
The Crontab format at a glance
Fields in order: minute (0-59), hour (0-23), day-of-month (1-31), month (1-12), day-of-week (0-7, 0 and 7 = Sunday).
Cron runs in the server's local time zone. Check it with the date command, or put CRON_TZ=Asia/Kolkata above the line on cronie-based systems.
The fixed schedule in other systems
If you are moving this schedule to another scheduler, these are the equivalents of 0 * * * *:
| System | Expression |
|---|---|
| Quartz | 0 0 * * * ? |
| Spring | 0 0 * * * * |
| Kubernetes | 0 * * * * |
| AWS EventBridge | 0 * * * ? * |
| Jenkins | 0 * * * * |
| GitHub Actions | 0 * * * * |
| node-cron | 0 * * * * |
| Apache Airflow | 0 * * * * |
| Azure Functions | 0 0 * * * * |
| Google Cloud Scheduler | 0 * * * * |
Try it yourself
The tester below starts with the fixed expression. Change it and watch the schedule update.
Your week at a glance
Upcoming runs
| # | Local | UTC | From now |
|---|
Copy-ready code
Frequently asked questions
What does "bad hour" or "bad day-of-week" mean?
The same thing for another field: hours are 0-23, day-of-week is 0-7.
More Crontab fixes
See the full Crontab cron builder or convert between formats.