Uptime monitoring

Simple uptime monitoring alerts to your phone.

Use cron, curl, or your own health-check script to send encrypted downtime alerts to iPhone and Android.

Why Nerve for uptime checks

You do not always need a full monitoring stack for a side project, VPS, or small production service. Nerve is a tiny encrypted push layer for the health checks you already know how to write.

Basic HTTP status check

#!/bin/sh
URL="https://example.com/health"
STATUS=$(curl -s -o /dev/null -w "%{http_code}" "$URL")

if [ "$STATUS" != "200" ]; then
  echo "DOWN: $URL returned $STATUS" | nerve send --severity critical
fi

Cron every minute

* * * * * NERVE_DSN="nerve://TOKEN:[email protected]" /usr/local/bin/check-site.sh

Latency threshold alert

TIME=$(curl -s -o /dev/null -w "%{time_total}" https://example.com)
awk "BEGIN { exit !($TIME > 2.0) }" \
  && echo "SLOW: example.com took ${TIME}s" | nerve send --severity alert

Multiple endpoints

for url in https://app.example.com/health https://api.example.com/status; do
  code=$(curl -s -o /dev/null -w "%{http_code}" "$url")
  if [ "$code" != "200" ]; then
    echo "health check failed: $url -> $code" | nerve send --severity critical
  fi
done

FAQ

Reduce false positives

For public websites, alert after multiple consecutive failures rather than one missed request. A single timeout can be network noise; three failed checks in a row usually means a real incident.

code=$(curl -s -o /dev/null -w "%{http_code}" --max-time 10 https://example.com/health || echo 000)
[ "$code" != "200" ] && echo "health failed: example.com -> $code" | nerve send --severity alert

Check the body too

HTTP 200 does not always mean healthy. A maintenance page, CDN error page, or empty JSON response can still return 200. Add a small body check for the value your app should return.

Can I use Nerve for uptime monitoring?

Yes. Run a small cron job that checks your endpoint with curl and pipes failures to nerve send.

Does Nerve replace full monitoring platforms?

No. Nerve is a lightweight encrypted alert channel. It works well as a simple push layer for scripts, cron jobs, and health checks.

Are uptime alerts encrypted?

Yes. The alert text is encrypted before it reaches the relay.