Quick answer
The cron expression for every week is 0 0 * * 0, which is what the @weekly macro expands to: once a week at 00:00 on Sunday. Cron has no weekly interval as such, so a weekly job is really a day of the week plus a time. Any day works, for example 0 0 * * 1 for Monday at midnight.
- Live next runs
- Any time zone
- Field-by-field breakdown
- Seven platform snippets
- Daylight saving aware
How to use this schedule
- 1Copy
0 0 * * 0with the Copy expression button. - 2Check Next runs in your time zone to confirm it fires when you expect, including around daylight saving changes.
- 3Pick your platform under Use it on your platform and copy the ready-made crontab line, workflow, manifest or timer.
- 4Need a different time or day? Click Customize to open it in the cron expression generator and change any field.
Does @weekly mean Sunday or Monday?
It depends on the tool, and that surprises people moving jobs between cron and systemd:
| Tool | Weekly shorthand | Runs at |
|---|---|---|
| crontab (Vixie cron, cronie) | @weekly | Sunday 00:00 (0 0 * * 0) |
| Kubernetes CronJob | @weekly | Sunday 00:00 |
| GitHub Actions | none (macros aren't accepted) | Write 0 0 * * 0 |
| systemd timer | OnCalendar=weekly | Monday 00:00 |
So a weekly job that moves from a crontab to a systemd timer quietly shifts by a day unless you spell the day out, for example OnCalendar=Sun *-*-* 00:00:00. Writing all five cron fields instead of a macro avoids the question entirely and makes the day obvious to the next person who reads the file.
Why doesn't */7 in the day-of-month field mean every 7 days?
Because steps restart every month. 0 0 */7 * * matches days 1, 8, 15, 22 and 29, then the 1st of the next month, so the last gap of most months is only one to three days. It looks weekly, but it isn't.
Cron has no notion of "every N days since a start date". For a strict seven-day cycle, use a fixed weekday: 0 0 * * 0 is exactly seven days apart every time. For every two weeks, run weekly and let the job skip alternate weeks based on the ISO week number, or use a scheduler with real intervals. Choosing the day itself is a separate decision: Monday suits work-week reporting, while Sunday is the quieter maintenance day.
What does each field in 0 0 * * 0 mean?
| Field | Value | Allowed | Meaning |
|---|---|---|---|
| Minute | 0 | 0–59 | at minute 0 (on the hour) |
| Hour | 0 | 0–23 | at hour 0 (midnight) |
| Day of month | * | 1–31 | every day of the month |
| Month | * | 1–12, JAN–DEC | every month |
| Day of week | 0 | 0–7 (0 and 7 are Sunday), SUN–SAT | only on Sunday |
Read together: Once a week at 00:00 on Sunday, the same as @weekly.
How do I adjust 0 0 * * 0 to my own schedule?
Small edits to 0 0 * * 0 cover most real-world needs:
| Expression | What it does |
|---|---|
0 0 * * 1 | Weekly on Monday at midnight |
0 3 * * 0 | Weekly on Sunday at 3 AM |
0 12 * * 3 | Weekly on Wednesday at noon, mid-week |
0 9 * * 5 | Weekly on Friday at 9 AM |
0 0 */7 * * | Not weekly: days 1, 8, 15, 22 and 29 of each month |
Need something else? Click Customize at the top of the page to open this schedule in the cron expression generator and change any field.
Related schedules: Every Sunday · Every Monday · Every weekend · Every month
Browse all schedules in the cron schedule library.
How do I run 0 0 * * 0 in crontab, GitHub Actions, Kubernetes and the cloud?
| Platform | Write it as | Time zone |
|---|---|---|
| Linux crontab | 0 0 * * 0 | Server's time zone; CRON_TZ= in cronie |
| GitHub Actions | - cron: "0 0 * * 0" | UTC by default; add timezone: (IANA name) |
| Kubernetes CronJob | schedule: "0 0 * * 0" | Set timeZone: (1.27+) |
| Cloudflare Workers | 0 0 * * SUN | UTC only; numbers weekdays from 1 = Sunday, so use names |
| Vercel Cron Jobs | 0 0 * * 0 | UTC only; Hobby runs it within the hour (±59 min) |
| AWS EventBridge Scheduler | cron(0 0 ? * SUN *) | Takes a time zone; legacy scheduled rules are UTC only |
| systemd timer | OnCalendar=Sun *-*-* 00:00:00 | Add a zone after the time, e.g. Europe/London |
In a crontab (crontab -e), the full line looks like this:
0 0 * * 0 /path/to/job.sh >> /var/log/job.log 2>&1The live panel at the top of the page builds complete, copy-ready files for each platform (workflow, CronJob manifest, wrangler.toml, vercel.json, AWS CLI and systemd units) and can shift the schedule to UTC for platforms that need it.
What can go wrong with 0 0 * * 0?
- systemd's
weeklyis Monday 00:00, while cron's@weeklyis Sunday 00:00. Spell the day out when you migrate a job. */7in the day-of-month field restarts on the 1st, so it is not every seven days. Use a fixed day of the week instead.- Plain cron skips a weekly run if the machine is off at that moment, and the next try is a week later. anacron and systemd timers with
Persistent=truecatch up instead. - A weekly job that fails silently can go unnoticed for weeks. Alert on failure, or ping a heartbeat monitor on success.
- On UTC-only platforms (Cloudflare Workers, Vercel, legacy EventBridge rules), the local time this runs at moves by an hour when daylight saving time starts or ends. Use GitHub's
timezone:, KubernetestimeZone, EventBridge Scheduler or cronie'sCRON_TZto pin it to local time.
Frequently asked questions
Last updated by the Playxoft engineering team.