Status Monitor – Documentation

A lightweight, file-based uptime monitoring system written in PHP.

Overview

The Status Monitor system provides real-time HTTP status checks for any number of websites. It saves uptime history to a JSON file, automatically fills gaps in monitoring, and generates a modern dashboard using index.php.

Main components:
check.php – performs website checks and updates the JSON history
index.php – displays the live status dashboard
config.php – general configuration & SEO settings
sites.php – list of monitored websites
status.json – automatically generated monitoring log

check.php – Monitoring Engine

This script performs all uptime checks. It sends an HTTP HEAD request to each website listed in sites.php and stores the results in status.json.

Features

Requirements

Cron Example

* * * * * php /path/to/check.php > /dev/null 2>&1

config.php – Configuration

This file defines site branding, SEO templates, and monitoring period settings.

Includes:

Example

$siteName = "Example";
$siteStatus = "Status Monitor";
$monitoringPeriod = "3 hours";
    

sites.php – Website List

This file contains an array of websites to be monitored. Each entry must include a human-readable name and a full URL.

return [
    [
        'name' => 'My Website',
        'url'  => 'https://example.com',
    ],
];
    

index.php – Status Dashboard

This file generates the entire status web interface. It loads status.json, computes uptime %, detects outages, and visualizes the last 6 hours of data using Chart.js.

Main features

Charts

Line charts display values:

Data Storage (status.json)

All monitoring data is stored under status.json in a simple key/value structure:

{
    "My Website": {
        "2025-12-02T10:20:00Z": "up",
        "2025-12-02T10:22:00Z": "down"
    }
}
    

Easy to parse, easy to back up, no database required.