A lightweight LAN-based system monitoring tool built with FastAPI + WebSockets. It allows you to monitor CPU, RAM, Disk, Processes, and Network usage of your system from any device on your local network via a browser.
- 📊 Real-time system metrics (CPU, RAM, Disk, Processes, Network)
- 🌍 Access from any device on the same LAN (PC, phone, tablet)
- 🔒 Token-based authentication
- ⚡ Fast, asynchronous backend using FastAPI + Uvicorn
- 🖥️ Web dashboard auto-refreshes metrics every second
LAN-System-Monitor/
│── main.py # Main application script
│── requirements.txt
│── README.md
│── dist/ # (generated after building exe with PyInstaller)
│── venv/ # (optional, local virtual environment)
git clone https://github.com/yourusername/LAN-System-Monitor.git
cd LAN-System-Monitorpython -m venv venv
source venv/bin/activate # on Linux / Mac
venv\Scripts\activate # on Windowspip install -r requirements.txtIf you don’t have requirements.txt yet, create it with:
fastapi
uvicorn
psutilpython main.pyYou’ll see output like:
Agent URL: http://192.168.1.42:8765
Auth token: 'change-me'
Open that URL in your browser (PC or mobile), enter the token, and start monitoring.
The agent uses environment variables for customization:
AGENT_PORT→ Server port (default:8765)AGENT_TOKEN→ Auth token (default:change-me)
Example (Linux/macOS):
export AGENT_PORT=9000
export AGENT_TOKEN=super-secret
python main.pyExample (Windows PowerShell):
$env:AGENT_PORT="9000"
$env:AGENT_TOKEN="super-secret"
python main.pyUse PyInstaller to create a single-file executable:
pip install pyinstaller
pyinstaller --onefile main.pyThe EXE will be generated in the dist/ folder.
Run it directly:
dist\main.exe

