CrontiqGuides › GitHub Badge

How to Add a Cron Monitoring Badge to Your GitHub README

Status badges are a staple of well-maintained open source projects. Build status, test coverage, npm version — they give visitors an instant signal that the project is healthy and actively maintained. But one category of status has been missing from most READMEs: cron job health.

If your project includes scheduled tasks — data imports, feed generation, cache rebuilds, certificate renewals — a live cron monitoring badge tells contributors and users that those background processes are actually running. This guide shows you how to set one up with Crontiq in under five minutes.

Why Cron Status Badges Matter

For open source projects that rely on scheduled jobs, the badge answers a question that documentation cannot: is it running right now? A README can describe the cron setup, but only a live badge proves it is working.

Common use cases for cron status badges:

The badge also serves as a transparency signal. Users can click through to a public status page with sparkline charts showing recent ping history, without needing any login or access to your infrastructure.

Step-by-Step Setup

Step 1: Create a Crontiq Account

Register at crontiq.io/register with your email address. You will receive an API key (starting with cq_live_) and can manage your monitors from the dashboard.

Step 2: Set Up the Monitor

Add a curl call to your cron job. The monitor is auto-provisioned on the first ping — no dashboard configuration needed:

# Example: nightly data sync job 0 3 * * * /opt/scripts/sync.sh \ && curl -fsS -o /dev/null \ https://ping.crontiq.io/p/cq_live_YOUR_KEY/data-sync

After the first ping, Crontiq creates the monitor data-sync and assigns it a public token (starting with cq_chk_). You can find this token in the dashboard under the monitor settings.

Step 3: Get the Badge URL

Every monitor has an SVG badge endpoint. The URL format is:

https://crontiq.io/badge/cq_chk_YOUR_PUBLIC_TOKEN.svg

The badge dynamically reflects the current monitor status:

Step 4: Add the Badge to Your README

Use standard Markdown image syntax. Link the badge to your public status page so visitors can click through for details:

[![Cron Status](https://crontiq.io/badge/cq_chk_YOUR_TOKEN.svg)](https://crontiq.io/public/cq_chk_YOUR_TOKEN)

For HTML-based READMEs or documentation sites:

<a href="https://crontiq.io/public/cq_chk_YOUR_TOKEN"> <img src="https://crontiq.io/badge/cq_chk_YOUR_TOKEN.svg" alt="Cron job status" /> </a>

Place the badge near the top of your README, alongside other status badges like CI/CD and test coverage.

Customizing the Badge

Custom Labels

By default, the badge displays "crontiq" on the left side and the status on the right. You can customize the label with the label query parameter:

# Default: "crontiq | up" https://crontiq.io/badge/cq_chk_YOUR_TOKEN.svg # Custom label: "data sync | up" https://crontiq.io/badge/cq_chk_YOUR_TOKEN.svg?label=data%20sync # Custom label: "nightly backup | up" https://crontiq.io/badge/cq_chk_YOUR_TOKEN.svg?label=nightly%20backup

Showing Metrics on the Badge

If your cron job sends JSON metrics, you can display a specific metric value on the badge instead of the status text:

# Show row count: "SIRENE | 45,200 rows" https://crontiq.io/badge/cq_chk_YOUR_TOKEN.svg?metric=rows&label=SIRENE # Show duration: "backup | 12.4s" https://crontiq.io/badge/cq_chk_YOUR_TOKEN.svg?metric=duration_seconds&label=backup

This turns the badge into a live data display. For data-oriented projects, showing the latest row count or processing time is more informative than a simple "up" status.

Multiple Badges

If your project has multiple cron jobs, add a badge for each one. This gives visitors a complete picture of your background infrastructure:

## Status [![Data Sync](https://crontiq.io/badge/cq_chk_TOKEN1.svg?label=data%20sync)](https://crontiq.io/public/cq_chk_TOKEN1) [![Backup](https://crontiq.io/badge/cq_chk_TOKEN2.svg?label=backup)](https://crontiq.io/public/cq_chk_TOKEN2) [![Feed Gen](https://crontiq.io/badge/cq_chk_TOKEN3.svg?label=feed)](https://crontiq.io/public/cq_chk_TOKEN3)

Caching and Freshness

Crontiq serves badge SVGs with a Cache-Control header that allows CDNs and browsers to cache the image for 60 seconds. This means the badge may take up to one minute to reflect a status change. For most cron jobs that run hourly or daily, this is more than sufficient.

GitHub's own CDN (camo) also caches images. If you need GitHub to refresh the badge more frequently, you can append a cache-busting query parameter:

# GitHub will re-fetch when the URL changes ![Status](https://crontiq.io/badge/cq_chk_TOKEN.svg?v=2)

In practice, GitHub re-fetches badge images every few minutes for active repositories, so manual cache-busting is rarely needed.

The Public Status Page

When visitors click the badge, they land on a public status page at crontiq.io/public/{token}. This page displays:

No login is required. The public token (cq_chk_) provides read-only access to the monitor status. It cannot be used to send pings, modify settings, or access other monitors on your account.

Get your cron badge — free