create an account
go to ping-guard.com/register and sign up with your email or github account. no credit card required.
create your first monitor
from your dashboard, click new monitor. fill in:
- name — a label for this job (e.g. daily-backup)
- interval — how often the job runs (e.g. every 1 hour)
- grace period — how late a ping can arrive before we alert (default: 5 minutes)
copy your ping url
after saving, you'll see a unique ping url like:
https://ping-guard.com/p/YOUR_SLUGthis url is what your cron job will call when it finishes successfully.
add to your cron job
append a curl call to the end of your cron command using the && operator. the ping is only sent if your command succeeds.
# basic usage
your-command && curl -fsS https://ping-guard.com/p/YOUR_SLUG
# crontab example (runs every hour)
0 * * * * /usr/local/bin/backup.sh && curl -fsS https://ping-guard.com/p/YOUR_SLUG
# silence curl output completely
your-command && curl -fsS --retry 3 -o /dev/null https://ping-guard.com/p/YOUR_SLUGthe -fsS flags: -f fail silently on HTTP errors, -s silent mode, -S still show errors if -s is set.
verify it works
after your first ping arrives, the monitor status changes to up. you can also trigger a test ping manually from the dashboard.
pingguard will wait up to interval + grace period before marking the monitor as missed and sending an alert.
what happens when a ping is missed
1. your monitor's deadline passes (interval + grace period).
2. pingguard marks the monitor as missed.
3. an alert is sent to all configured channels (email by default).
4. the monitor stays in missed state until the next successful ping arrives.
code examples
bash
#!/bin/bash
# run your job, then ping on success
/usr/local/bin/my-backup-script.sh \
&& curl -fsS https://ping-guard.com/p/YOUR_SLUGpython
import urllib.request
def run_job():
# your job logic here
pass
def ping_success(slug: str):
url = f"https://ping-guard.com/p/{slug}"
urllib.request.urlopen(url, timeout=10)
if __name__ == "__main__":
run_job()
ping_success("YOUR_SLUG")node.js
const https = require('https');
function runJob() {
// your job logic here
}
async function pingSuccess(slug) {
await fetch(`https://ping-guard.com/p/${slug}`);
}
(async () => {
runJob();
await pingSuccess('YOUR_SLUG');
})();php
<?php
function runJob(): void {
// your job logic here
}
function pingSuccess(string $slug): void {
$url = "https://ping-guard.com/p/{$slug}";
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_TIMEOUT, 10);
curl_exec($ch);
curl_close($ch);
}
runJob();
pingSuccess('YOUR_SLUG');