~/devtools / cron / every-week
tool::cron-guide

cron every-week

0 0 * * 0

Every Sunday

ad · 728×90
Field Breakdown
0
Minute (0–59)
at 0
0
Hour (0–23)
at 0
*
Day of Month (1–31)
any
*
Month (1–12)
any
0
Day of Week (0–6)
at 0
0–59
0–23
1–31
1–12
0–6 (Sun–Sat)

Runs once a week at Sunday midnight. The day-of-week field value 0 represents Sunday (6 also works for Saturday). Perfect for heavier weekly maintenance tasks that would be too expensive to run daily.

Next 5 Executions (Example)
UTC example times after 2026-01-01
#1Sun, Jan 4, 2026, 12:00 AM UTC
#2Sun, Jan 11, 2026, 12:00 AM UTC
#3Sun, Jan 18, 2026, 12:00 AM UTC
#4Sun, Jan 25, 2026, 12:00 AM UTC
#5Sun, Feb 1, 2026, 12:00 AM UTC

Platform Usage

Linux CrontabRun crontab -e and add the line
# crontab -e
0 0 * * 0 /path/to/script.sh
# With logging:
0 0 * * 0 /path/to/script.sh >> /var/log/myjob.log 2>&1
Kubernetes CronJobSet in spec.schedule field
apiVersion: batch/v1
kind: CronJob
metadata:
  name: my-cronjob
spec:
  schedule: "0 0 * * 0"
  jobTemplate:
    spec:
      template:
        spec:
          containers:
          - name: my-job
            image: my-image:latest
          restartPolicy: OnFailure
GitHub ActionsAdd to on.schedule trigger
on:
  schedule:
    - cron: '0 0 * * 0'

jobs:
  my-job:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - run: ./my-script.sh

Common Use Cases

  • Full weekly database backups
  • Weekly performance report generation
  • Pruning unused Docker images
  • Weekly security vulnerability scans
  • Archiving old log files

Related Presets

0 0 * * 1every monday* * * * *every minute*/5 * * * *every 5 minutes*/10 * * * *every 10 minutes
ad · 300×250
Back to Cron Builder
// related tools
jwt
JWT Decoder
Decode and inspect JWT tokens. View header, payload, and signature details.
rx
Regex Tester
Test regular expressions with live matching, group highlighting, and explanations.
Color Converter
Convert colors between HEX, RGB, HSL, and more. Pick colors visually.
ts
Timestamp Converter
Convert Unix timestamps to human-readable dates. Supports ms/s, UTC/local, and relative time.