Setting up a cron job (scheduled task)

Running scripts automatically at set times.

Hosting and DirectAdmin ~1 min read Updated: 30.09.2026
  1. In DirectAdmin, open Advanced Features → Cronjobs.
  2. Choose the timing: minute, hour, day, month, weekday. For example, every 5 minutes: minute */5, the rest *.
  3. Enter the command and create it.

Example commands:

  • PHP script: /usr/local/bin/php /home/account/domains/yourdomain/public_html/cron.php
  • Calling a URL: curl -s https://yourdomain/cron >/dev/null 2>&1
Heavy scripts that run too often (every minute) can exhaust your account’s resources — choose the minimum frequency you need.
Problem not solved?

Our team is here 24/7 — open a ticket or write to the AI Advisor.