Cron Expression Generator and Explainer

Paste a cron schedule or pick an example. The tool checks each field, explains the schedule in plain English and lists the next five run times in your time zone. Everything runs in your browser; nothing is sent to our server.

Five fields: minute, hour, day of month, month, day of week. Or a shortcut like @daily.

How to read a cron expression

A crontab line starts with five time fields, then the command: minute hour day-of-month month day-of-week command. A star means every value, a comma separates a list (1,15), a dash is a range (1-5) and a slash sets a step (*/10 is every tenth value).

The tool follows the rules of the cron used on Debian and Ubuntu (Vixie cron). That cron does not accept a step on a single number such as 5/10, so the tool tells you to write 5-59/10 instead, and it treats day of month and day of week the way cron does: when both are set, either one is enough.

Questions

What do the five fields of a cron expression mean?

From left to right: minute (0-59), hour (0-23), day of month (1-31), month (1-12 or jan-dec) and day of week (0-7 or sun-sat, where both 0 and 7 mean Sunday). A star means every value.

How do I run a cron job every 5 minutes?

Use */5 * * * * followed by the command. The */5 in the minute field means every fifth minute: 0, 5, 10 and so on.

What happens when I set both day of month and day of week?

Standard cron (Vixie cron, used by Debian and Ubuntu) runs the job when either field matches. For example 0 9 1 * 1 runs at 09:00 on the 1st of every month and on every Monday.

Which time zone does cron use?

Cron uses the server’s local time zone. Check it with timedatectl. This tool shows the next run times in your browser’s time zone, so compare the two if they differ.

How do I add the job to my server?

Run crontab -e as the user who should run the job, add the line with the full path to the command, save and close. List your jobs with crontab -l. System-wide jobs in /etc/crontab and /etc/cron.d also need a user name between the schedule and the command.

Next step: add and manage cron jobs on Debian, or browse all free tools.