Overview
Cron Jobs allow you to automate tasks on your website, such as running scripts, clearing temporary files, sending email reports, or executing backups. DirectAdmin includes an easy-to-use Cron Manager.
Where to find Cron Jobs
Log in to DirectAdmin → Advanced Features → Cron Jobs
How to create a new Cron Job
- Open the Cron Jobs page
- Click Create Cron Job
- Set the schedule (minute, hour, day, month, weekday)
- Enter the command you want to run
- Click Create
Common schedule examples
Run a script every day at midnight
0 0 * * * php -q /home/username/domains/yourdomain.com/public_html/script.php
Run a script every 5 minutes
*/5 * * * * php -q /path/to/cron.php
WordPress Cron replacement (recommended)
*/5 * * * * php -q /home/username/domains/yourdomain.com/public_html/wp-cron.php
Email notifications for Cron Jobs
To receive email output from a Cron Job:
@reboot echo "Cron started"
To disable notifications, add at the end of the command:
>/dev/null 2>&1
Troubleshooting
- Script not executing – wrong file path.
- Permission denied – file needs CHMOD 755.
- PHP not found – Use the full path to the PHP binary.