Skip to main content
TrustServers Knowledge Base

Tip: Start typing to get instant search results.

Table of Contents

How to Create a Cron Job via DirectAdmin Control Panel

Cron jobs are scheduled processes that run on the server at the frequency you desire, allowing periodic execution of commands you need for your website. To manage your cron jobs:

  1. Log in to DirectAdmin by typing your domain (domainname.tld:2222) in the browser and login by entering your username and password.

  2. Select Cron Jobs from the Advanced Features menu and then click the button:
    “+ CREATE CRON JOB”.

  3. Next, we define the cron job execution schedule by filling in the appropriate fields and simultaneously enter the command to be executed in the ‘Command’ field.
    We can verify the correctness of the schedule from the description displayed on the right, as shown in the screenshot below.
    In the example, we have set a cron job to run every day and every hour at “half past”.
    For example, it will run at 00:30, 01:30, 02:30, …, up to 23:30 all day long.
    The command being executed is:

    curl http://yourwebsite.com/wp-cron.php?doing_wp_cron >/dev/null 2>&1
    This command triggers the WordPress cron system (wp-cron.php) via HTTP request and ensures that the command output is discarded (based on the logic that we don’t care about the output).

    Finally, click the “CREATE” button to save and activate the new cron job.

  4. Finally, from the same Cron Jobs tab we can view all the cron jobs we have created, modify them, or create a new cron job.
Was this article helpful?
Please Share Your Feedback
Πώς μπορεί να βελτιωθεί το άρθρο;
Privacy Overview

This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.