Intermediate 15 min

Planned tasks (cron) on web hosting

Automate WordPress wp-cron, PHP scripts and synchronizations with the cron tasks of the shared hosting panel.

#Cron#Planned tasks#WordPress#Automatization

Ready to start your service? Check offers and order online.

View offers and order

Scheduled Cron Tasks on Web Hosting

The tasks cron run PHP scripts or commands at regular intervals on your web hosting Anthony IT Solutions: sending newsletters, cache purging, WooCommerce imports or automatic backups.

WordPress uses wp-cron by default; on shared hosting, a real cron system via the panel is more reliable and efficient.

In summary Configure the cron in the panel; point to a PHP URL or script; test manually before planning.

What you need

  • Active web hosting
  • Access panel
  • Script or URL to run
  • Frequency understanding (minute/hour/day)

Understanding cron vs wp-cron

wp-cron is triggered at each visit, imprecise on sites not frequented.

MethodBenefitsDisadvantages
Wp-cronNo configDelayed so little traffic
Cron panelAccurate, reliableInitial configuration
wget/curl URLSimple WordPressExtra HTTP charge

Access the cron planner

  1. Panel

    Section Cron or Planned tasks of the web hosting panel.

  2. New Task

    Button Add: command, frequency, optional e-mail notification.

  3. Syntax crontab

    Format: minute hour day month day_week order.

  4. Time zone

    Server in Europe/Paris, adjust the shipping times.

Cron WordPress (recommended)

  1. Disable wp-cron

    In wp-config.php : define('DISABLE_WP_CRON', true);

  2. Command wget

    wget -q -O - https://votredomaine.fr/wp-cron.php?doing_wp_cron >/dev/null 2>&1

  3. Frequency

    Every 5 or 15 minutes according to plugins (Action Scheduler).

  4. Check

    Install WP Cortrol to see the planned hooks.

Cron PHP script CLI

  1. Absolute path

    /usr/bin/php /home/user/public_html/script.php, path displayed in the panel.

  2. Rationales

    Pass parameters: script.php import daily

  3. Logs

    Redirect exit: >>/home/user/logs/cron.log 2>&1

  4. Permissions

    Executable Script 755; correct owner.

Common examples

  • Daily BDD Backup, guards
  • Purge LiteSpeed Cache
  • Import PrestaShop catalogue
  • Send queue emails
  • **Monitor and troubleshoot**, see detailed procedures.

Troubleshooting

  • Cron does not run, Syntax crontab or wrong PHP path.
  • 403 on wget, Hotlink or IP protection; whitelistez localhost.
  • Double execution, wp-cron AND cron panel active simultaneously.
  • Script timeout, Optimize or cut the processing.

Frequently Asked Questions

Minimum interval ?
Often 1 minute on mutualised; respect fair-use limits.

SSH required?
No, the panel is sufficient for most tasks.

Cron and Multisite?
One entry per site or wp-cli network, multisite.

Alternative wp-cron ?
Plugins like WP Cortrol to diagnose without deactivating.

Related guides

See also our web hosting offer and all the procedures on wiki web hosting.