What is a cron expression?
A cron expression is a short string that tells a scheduler when to run a job. It is used by Linux/Unix crontab, cPanel cron jobs, Kubernetes CronJobs, GitHub Actions schedules, Laravel's scheduler, AWS EventBridge and many other tools. A standard expression has five fields separated by spaces:
│ ┌──── hour (0–23)
│ │ ┌──── day of month (1–31)
│ │ │ ┌──── month (1–12 or JAN–DEC)
│ │ │ │ ┌──── day of week (0–7 or SUN–SAT; 0 and 7 are Sunday)
* * * * *
Special characters
| Symbol | Meaning | Example |
|---|---|---|
* | Every value | * * * * * runs every minute |
, | List of values | 0 9,17 * * * runs at 9:00 and 17:00 |
- | Range | 0 9 * * 1-5 runs at 9:00 on weekdays |
/ | Step | */15 * * * * runs every 15 minutes |
Common cron examples
| Expression | Runs |
|---|---|
*/5 * * * * | Every 5 minutes |
0 * * * * | At the start of every hour |
0 0 * * * | Every day at midnight |
30 2 * * 0 | Sundays at 02:30 |
0 9 1 * * | 09:00 on the 1st of every month |
0 0 1 1 * | Midnight on January 1 |
The day-of-month and day-of-week rule
A detail that surprises many people: if both day of month and day of week are restricted (neither is *), standard cron runs the job when either matches, not both. 0 0 13 * 5 runs on every 13th and on every Friday, not only on Friday the 13th. This tool follows that rule when it calculates next run times.
Things to check before deploying
- Time zone: cron runs in the server's time zone, which is often UTC. The next run times here are shown in your local time, so adjust if your server differs.
- Seconds and years: some systems, such as Quartz and Spring, use 6–7 fields that include seconds and years. This tool uses the standard 5-field format.
- Overlap: make sure a job finishes before the next run starts, or use a lock.
- Output: redirect output to a log file (
>> /path/job.log 2>&1) so failures aren't silent.
Working with timestamps in your jobs? Try the Unix timestamp converter.
Frequently asked questions
What does * * * * * mean in cron?
Run every minute of every hour of every day.
How do I run a cron job every 5 minutes?
Use */5 * * * *.
Is Sunday 0 or 7 in cron?
Both. Most cron implementations accept 0 and 7 for Sunday.
What time zone does cron use?
The time zone of the server or the scheduler's configuration, often UTC on cloud servers. Some schedulers let you set a time zone per job.
Last updated December 2, 2026.