Cron Expression Generator

Build cron expressions with a visual editor.

Cron Expression

* * * * *

Every minute

Quick presets:

0-59

0-23

1-31

1-12

0-6 (Sun-Sat)

What is a Cron Expression?

A cron expression is a compact string that defines a recurring schedule. Originating from the Unix cron daemon (first introduced in Version 7 Unix in 1979), cron expressions are now used across virtually all scheduling systems: Linux crontab, CI/CD pipelines (GitHub Actions, GitLab CI), cloud schedulers (AWS EventBridge, GCP Cloud Scheduler), and application frameworks (Spring, Celery, node-cron).

The standard format uses five fields separated by spaces, each representing a time component. The cron daemon checks the current time against these fields every minute and runs the associated command when all fields match.

* * * * *

| | | | +-- Day of week (0-6, Sun-Sat)

| | | +---- Month (1-12)

| | +------ Day of month (1-31)

| +-------- Hour (0-23)

+---------- Minute (0-59)

Special Characters

CharacterMeaningExample
*Any value* * * * *
,Value list1,3,5 * * * *
-Range* 9-17 * * *
/Step values*/5 * * * *

Common Cron Expressions

Every minute* * * * *
Every 5 minutes*/5 * * * *
Every hour0 * * * *
Daily at midnight0 0 * * *
Weekdays at 9am0 9 * * 1-5
Every Sunday at 3am0 3 * * 0
1st of every month0 0 1 * *
Every 15 min, business hours*/15 9-17 * * 1-5

Frequently Asked Questions

How do I add a cron job on Linux?
Run crontab -e to open your user's crontab file. Add a line with the cron expression followed by the command to run. For example: 0 2 * * * /home/user/backup.sh runs backup.sh every day at 2:00 AM. Use crontab -l to list existing jobs. Always use full paths for commands and redirect output: >> /var/log/backup.log 2>&1.
What timezone does cron use?
By default, cron uses the system timezone. On most servers, this is UTC. You can set a specific timezone by adding CRON_TZ=America/New_York at the top of your crontab (supported on many modern systems). In cloud environments, AWS EventBridge supports timezone-aware scheduling, while Kubernetes CronJobs default to the kube-controller-manager timezone. Always verify your server's timezone with timedatectl or date.
How do I know if my cron job is running?
Check the system logs: grep CRON /var/log/syslog (Ubuntu) or journalctl -u cron (systemd). For reliable monitoring, use a dead man's switch service like CronSignal that alerts you if a job fails to run on schedule. This catches silent failures that log-checking might miss.
Can I use cron expressions in GitHub Actions?
Yes, GitHub Actions uses standard 5-field cron expressions with the schedule trigger. Example: on: schedule: - cron: '0 9 * * 1-5'. Note that GitHub Actions schedules run in UTC and may have a delay of up to 15-20 minutes during peak times. For time-sensitive tasks, consider using a dedicated scheduler.

Related Tools

Monitor your cron jobs

Built a cron schedule? Make sure it actually runs. CronSignal monitors your cron jobs and alerts you if they fail to run on time. Need to monitor the endpoints your cron jobs hit? UptimeSignal has you covered.