Run a Cron Job Every Day at 9 PM
To run a job every day at 9:00 PM, use 0 21 * * *. Cron uses a 24-hour clock, so 9 PM is hour 21. The leading 0 is the minute.
The expression
0 21 * * * fires at 21:00 (9 PM) every day. Minute = 0, hour = 21, the rest wildcards.
Why 21, not 9
Cron hours run 0–23. Add 12 to a PM time: 9 PM = 21. 9 AM stays 9.
Minute and day tweaks
For 9:30 PM use 30 21 * * *. Weekends only: 0 21 * * 6,0 (Saturday and Sunday).
FAQ
What is the cron expression for every day at 9 PM?
0 21 * * * runs daily at 9:00 PM. In cron's 24-hour clock, 9 PM is hour 21.
Why is 9 PM 21 in cron?
Cron uses hours 0-23. Add 12 to a PM time, so 9 PM becomes 21. (9 AM stays 9.)
How do I run at 9 PM on weekends only?
Use 0 21 * * 6,0. In the day-of-week field 6 is Saturday and 0 is Sunday.