Search tools

Cron expression for every week

0 0 * * 0 runs a job once a week, at midnight at the start of Sunday. @weekly is the same schedule.

Runs entirely in your browser. Nothing you paste is sent to our server, stored or logged.

0 0 * * 0

When it runs next

What it means

The weekly shortcut treats Sunday as the first day of the week. If your week starts on Monday, use 0 0 * * 1 instead. It matters for weekly reports: a job at the very start of Monday covers the whole of the previous week, Sunday included.

Give weekly maintenance such as backups and log cleanup a quiet slot. 0 3 * * 0 runs at 3:00 on Sunday morning, when most services see the least traffic.

Common variations

ExpressionRuns
0 9 * * 1Every Monday at 9:00
0 3 * * 0Every Sunday at 3:00
0 17 * * 5Every Friday at 17:00

As a crontab line

Add the command you want to run after the five fields, then save it with crontab -e:

0 0 * * 0 /path/to/script.sh

Open it in the cron expression generator