T
ToolPrime

Cron Expression for Weekly on Friday

Run a cron job every Friday at midnight using 0 0 * * 5. Ideal for end-of-week summaries and pre-weekend cleanup.

Expression

0 0 * * 5

At 00:00 every Friday

Use Cases

Code Examples

Crontab

# At 00:00 every Friday
0 0 * * 5 /path/to/your/script.sh

GitHub Actions

name: Scheduled Job
on:
  schedule:
    - cron: '0 0 * * 5'
jobs:
  run:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - run: echo "Running Weekly on Friday"

systemd Timer

[Unit]
Description=Weekly on Friday timer

[Timer]
OnCalendar=*-*-* *:*:00
Persistent=true

[Install]
WantedBy=timers.target

Tips

Frequently Asked Questions

How do I run a cron job on Friday afternoon?

Use 0 17 * * 5 to run at 5 PM every Friday, or adjust the hour to match your end-of-business time.

Can I run on both Monday and Friday?

Yes, use 0 0 * * 1,5 to run at midnight on both Monday and Friday.

Related Cron Expressions