Cron health overview page: summary cards, the checks with what was found and how to fix it, what cron is not getting done, the queues and the cron jobs.
Cron jobs tab: each cron job's average and slowest time and last failure, and the recent cron runs.
Queues tab: items waiting in each queue, the oldest item, a growing marker and the trend over recent runs.
Cron Health settings: email alerts to the Administrator role and two addresses, and the status URL for uptime monitors.
Alert email from Cron Health listing three new problems, each with how to fix it.
Core's Cron page with a Cron health line reading 3 problems, 1 warning.
Terminal running drush cron-health, showing each check's status and exiting with code 1.

This project is not covered by Drupal’s security advisory policy.

Cron Health shows what cron is not getting done, and why, and emails the people who need to know.

When cron stops or falls behind, nothing on a Drupal site says so. Scheduled content is not published, search results go out of date, queued work piles up and security updates are not checked. The Status report only says when cron last ran. Cron Health checks the work cron should be doing, finds the cron job or queue that is failing, slow or behind, and says in plain words how to fix it.

It is read-only: it does not change how cron runs, so it is safe to install on any live site, next to core cron, Drush, Automated Cron or Ultimate Cron.

What cron is not getting done

  • Scheduled content that is past its Scheduler publish or unpublish time.
  • Available updates that were not checked as often as they should be, so security updates may be missing.
  • Search indexes (core Search and Search API) that cron will not finish within a day.

Checks on cron itself

  • Cron is running: compared with the schedule it measures from the recent runs. After three missed runs, cron counts as stopped.
  • Stopped runs: a run that stopped on a PHP error, or that PHP stopped on a time or memory limit, with the cron job it stopped in.
  • Failing jobs: cron jobs and queue workers that throw errors, with the message, file and line.
  • Queue backlog: queue items that wait too long, and queues that grow from one run to the next.
  • Slow jobs: cron jobs that take too long on average.
  • Automated Cron: warns when only Automated Cron runs cron on a site with Internal Page Cache. Visits served from the page cache do not run Automated Cron, so cron can run far less often than it is set to.

Alerts

  • Email to every active user with the roles you choose, and to any other addresses: when a problem appears and when it is fixed, or once a day. A test email button shows that delivery works.
  • A stopped cron is still reported: the checks also run after ordinary visits, at most every 15 minutes.
  • A secret status URL for uptime monitors such as UptimeRobot or Better Stack. It answers OK, or PROBLEM with the HTTP status 503, so you are warned even when visitors only get cached pages, or the whole site is down.
  • drush cron-health prints the checks and exits with code 1 on a problem, for server monitors and deploy scripts.

Where to find it

  • Reports » Cron health, with the Cron jobs tab (each job's average and slowest time, last error, and the recent runs) and the Queues tab (items, oldest item and trend per queue).
  • A Cron health line on the Status report and at the top of core's Cron page.

How it works

Cron Health wraps the site's cron service to note when each run starts and ends and how the queues stand, and reads the messages core already logs on the cron channel for each job's time and errors. When Ultimate Cron runs cron, the job figures come from its own log. Nothing is sent to any outside service.

Other modules can add their own checks with the cron_health.check service tag.

Requirements

Drupal 11.3 or later, or Drupal 12. PHP 8.3 or later. No other modules are needed.

Similar projects

  • Ultimate Cron replaces how cron runs, with a schedule and a log for each job. Cron Health only watches, works with core cron, and reads Ultimate Cron's log when it is installed.
  • Queue UI lists queues and lets you process them. Cron Health shows which queues fall behind and why.
  • Monitoring is a general framework of sensors and thresholds. Cron Health is a ready-made, plain-language report for cron, with no setup.

Project information

Releases