What is a Cron Expression?
A cron expression is a string that represents a schedule for recurring tasks in Unix/Linux systems. It's used by:
- System administrators: Automate backups, log rotation, cleanup tasks
- DevOps engineers: Schedule deployments, health checks, data syncs
- Developers: Run batch jobs, send scheduled emails, generate reports
- Security teams: Schedule vulnerability scans, log analysis, certificate renewals
Cron is available on Linux, macOS, and via tools like AWS CloudWatch, GitHub Actions, and Kubernetes CronJobs.
Generated Cron Expression
* * * * *
Every minute
Quick Presets
Every Minute
* * * * *Every 5 Minutes
*/5 * * * *Every Hour
0 * * * *Daily at Midnight
0 0 * * *Weekdays 9 AM
0 9 * * 1-5Weekly (Sunday)
0 0 * * 0Monthly (1st)
0 0 1 * *Yearly (Jan 1)
0 0 1 1 *Minute
0-59 or *Hour
0-23 or *Day of Month
1-31 or *Month
1-12 or JAN-DECDay of Week
0-6 (0=Sun) or SUN-SATCron Syntax Reference
| Field | Values | Special Characters |
|---|---|---|
| Minute | 0-59 | * , - / |
| Hour | 0-23 | * , - / |
| Day of Month | 1-31 | * , - / ? |
| Month | 1-12 or JAN-DEC | * , - / |
| Day of Week | 0-6 or SUN-SAT | * , - / ? |
* = every value , = multiple values - = range / = step
Examples: */15 = every 15 1,15 = 1st and 15th 1-5 = 1 through 5