If you rely on WordPress scheduled tasks, be aware that your site needs a regular stream of visits for those tasks to run. This can be a problem with development or staging sites, or on live sites that get very little traffic.
There’s no automatic way to for your web site to create system level cron jobs, so it implements WordPress scheduled tasks by checking for tasks that need to be performed when pages on your site are visited. If you’ve scheduled the BackupBuddy plug-in to run backups at noon and six o’clock, the first visits to your site after 12:00:00 and 18:00:00 will trigger those tasks. Its a pretty smart way to approximate direct system cron access, but there’s a weakness. If there are no visits to your site at noon and six, or even for hours afterward, those WordPress scheduled tasks are not going to run until someone wanders by for a visit. In the case of BackupBuddy (for example), your scheduled tasks might require multiple WordPress “cron” triggers so single page loads at noon and six might start the tasks, but won’t be enough to finish them.
This issue is especially prevalent in a development or staging environment that is generally hidden from public view. These sites see traffic when a developer is actively working on them, but then may lie completely dormant for days on end. No traffic means no WordPress scheduled tasks will run. This can also be a problem with live production sites that see very little traffic. There are so many crawlers on the web that invariably some spider will come along to hit your site at some point, but if you’ve been scratching your head as to why your WordPress scheduled tasks run so late, or so off-schedule, this is probably why.
A Simple Fix
There’s a simple way to address this without worrying about system/server level cron access. Engage a site monitoring service to hit your site every five or ten minutes. We suggest StatusCake, which is easy to use and offers a free level of service that should get the job done for almost anyone. As a bonus, site monitoring can alert you if your site is down, which is never a bad thing. Another good alternative is UptimeRobot, which is also free and reliable. Both StatusCake and UptimeRobot offer premium or pro plans too, which will get you more monitors, shorter monitoring intervals, SMS alerts and other goodies. For the purpose of triggering your WordPress scheduled tasks, however, the free offerings will be just fine for you.
Our managed WordPress hosting takes care of this for you since we monitor every site we host, including development and staging environments. This ensures a regular stream of traffic to trigger scheduled tasks. We also have no problem implementing server level cron jobs at any time for sites that require that. Check us out!