Health Checks
Monitor project health with automated checks.
Automatically monitor your Supabase projects with scheduled health checks.
What Health Checks Monitor
- Container status - All containers running
- Service connectivity - Database, API, Auth accessible
- Resource usage - CPU, memory, disk
- Response times - API latency
Create Health Check Task
Via Web UI
- Navigate to Tasks
- Click New Task
- Select type: Health Check
- Configure:
- Name: "Production Health Check"
- Project: Select project
- Schedule: Every 5 minutes
- Click Create Task
Via API
curl -X POST https://supascale.example.com/api/v1/tasks \
-H "X-API-Key: your-api-key" \
-H "Content-Type: application/json" \
-d '{
"name": "Production Health Check",
"enabled": true,
"type": "health-check",
"projectId": "production",
"cronExpression": "*/5 * * * *",
"timezone": "UTC",
"healthCheckConfig": {
"checkContainers": true,
"checkConnectivity": true,
"alertOnFailure": true
}
}'
Schedule Options
| Schedule | Cron | Use Case |
|---|---|---|
| Every minute | * * * * * | Critical production |
| Every 5 minutes | */5 * * * * | Production (recommended) |
| Every 15 minutes | */15 * * * * | Staging |
| Every hour | 0 * * * * | Development |
Health Check Configuration
| Option | Description | Default |
|---|---|---|
checkContainers | Verify all containers running | true |
checkConnectivity | Test database/API connectivity | true |
alertOnFailure | Send notification on failure | true |
What Gets Checked
Container Status
Verifies all project containers are:
- Running (not stopped/exited)
- Healthy (passing health checks)
- Not restarting repeatedly
Database Connectivity
Tests PostgreSQL connection:
SELECT 1;
API Accessibility
Tests REST API endpoint:
GET /rest/v1/
Auth Service
Tests authentication service health:
GET /auth/v1/health
Viewing Results
Via Web UI
- Go to Tasks
- Find the health check task
- View Last Status and History
Via API
curl https://supascale.example.com/api/v1/tasks/task-123 \ -H "X-API-Key: your-api-key"
Response:
{
"id": "task-123",
"name": "Production Health Check",
"lastRun": "2026-01-19T12:00:00Z",
"lastStatus": "success",
"history": [
{
"executedAt": "2026-01-19T12:00:00Z",
"status": "success",
"duration": 2500,
"result": {
"containers": "healthy",
"database": "connected",
"api": "accessible"
}
}
]
}
Alerts
Email Notifications
Configure SMTP to receive alerts:
- Set up SMTP in Supascale settings
- Enable
alertOnFailurein health check config - Set notification email in settings
Alert Contents
Failed health check alerts include:
- Project name
- Failure reason
- Container status details
- Timestamp
Run Health Check Manually
Trigger immediate check:
curl -X POST https://supascale.example.com/api/v1/tasks/task-123/run \ -H "X-API-Key: your-api-key"
Best Practices
Frequency
- Production: Every 5 minutes
- Staging: Every 15-30 minutes
- Development: Hourly or as needed
Multiple Projects
Create separate health checks for each project:
- Allows different schedules
- Independent alerting
- Clearer history
Response to Failures
- Automatic: Configure alerts
- Manual: Investigate logs
- Escalation: Define response procedures
Troubleshooting
Health Check Always Failing
- Manually check project status
- Review container logs
- Verify network connectivity
- Check project isn't stopped
No Alerts Received
- Verify SMTP configuration
- Check spam folder
- Verify notification email is set
- Test SMTP with manual email
False Positives
- Increase check timeout
- Verify network stability
- Check for resource constraints
- Consider reducing check frequency