Skip to content

Realtime ping monitoring on localhost. React + Node.js + Chart.js. Change target, track latency and view loss.

License

Notifications You must be signed in to change notification settings

OleksandrZadvornyi/ping-monitor

Repository files navigation

Ping Monitor

License: MIT Version Changelog Made with Node.js Made with React Platform

📡 A simple, lightweight, real-time web app to monitor internet connection stability. Built with Node.js, Express, React and Chart.js. Runs locally on localhost.

Ping Monitor Screenshot Track your ping in real time with a clean, interactive latency graph.

🔧 Features

  • 📊 Real-time latency graph (smooth and responsive)
  • ⏱ Dynamic time range selector (60s to full session)
  • 🧠 Live statistics: average, min, max and current latency
  • ❌ Packet loss tracking (count & %)
  • 🌐 Change ping target (IP or domain) without restarting
  • 💡 Runs on localhost, no cloud or desktop install

📦 Tech Stack

  • Backend: Node.js + Express + ping
  • Frontend: React + Chart.js (react-chartjs-2)
  • Runner: concurrently to launch both servers
  • No database: data is stored in memory per session

🚀 Getting Started

1. Clone the repo

git clone https://github.com/OleksandrZadvornyi/ping-monitor.git
cd ping-monitor

2. Install all dependencies

npm install

3. Start the app (backend + frontend)

npm start

To stop the app, press Ctrl + C in the terminal.

🔍 Usage

  • The graph starts by pinging 8.8.8.8 by default
  • Use the input field to enter a new IP or domain and hit Change Target
  • Select a view range (e.g. "5m", "1h") to zoom in or out
  • Watch live latency changes and packet loss stats update

📁 Project Structure

ping-monitor/
├── backend/
│   ├── server.js          # Express API and ping loop control
│   └── pingWorker.js      # Handles pinging and target switching
├── frontend/
│   ├── src/
│   │   ├── components/
│   │   │   ├── StatsPanel.jsx
│   │   │   └── LatencyGraph.jsx
│   │   ├── App.jsx
│   │   └── main.jsx
├── package.json           # Runs both frontend/backend with concurrently
└── README.md

📝 Future Improvements

  • 🔴 Plot red spikes for packet loss
  • 💾 Export data to CSV
  • 🌙 Dark mode
  • 💡 System tray / background mode

❓ FAQ

Why does this run on localhost?

This app is intentionally local-only for two main reasons:

  • Privacy & security – your connection info stays on your machine
  • Low latency – it's meant for real-time monitoring

If hosted remotely, it wouldn’t accurately measure your own ping, but rather the ping between the server and the target.

📄 License

MIT

About

Realtime ping monitoring on localhost. React + Node.js + Chart.js. Change target, track latency and view loss.

Topics

Resources

License

Stars

Watchers

Forks

Contributors 2

  •  
  •