A lightweight Windows desktop utility that quietly watches your internet connection, records every disconnect/reconnect with exact timestamps and durations, shows the stats in a clean dashboard, and can email you a daily report.
It runs as a single .exe — no installer, no Windows service, no admin
rights, and no Python required on the machine that runs it. Everything lives
in the system tray.
Open Source · Free to Use — MIT licensed.
- One-file executable —
InternetMonitor.exebundles everything; nothing to install. - Lives in the system tray — closing a window doesn’t quit it; it keeps monitoring in the background until you choose Quit.
- Accurate, debounced detection — probes Google / Cloudflare / Quad9 DNS and only flags an outage after consecutive failures, so a single dropped packet won’t cause a false alarm.
- Dashboard with a date-range filter (24h / 7d / 30d / All or custom): availability %, uptime, downtime, outage count, longest & average outage, a color-coded timeline, and a full event log.
- Beautiful HTML reports generated on a schedule and on demand.
- Daily email report over SMTP (Gmail/Outlook/any server), at a time you choose.
- Launch at Windows startup — a built-in toggle (per-user, no admin), not a service.
- Crash-safe — all transitions are appended to
events.jsonl; the monitor resumes its state after a restart.
-
Download
InternetMonitor.exefrom the Releases page (or build it yourself — see below). -
Put it in any folder you like (it creates its data files next to itself).
-
Double-click it. A globe icon appears in the system tray (bottom-right).
-
Right-click the tray icon for the menu:
Menu item What it does Connection: … Shows the current state (Connected / Disconnected) Open Dashboard Live stats window with a date filter Settings Monitoring options + email setup View Latest Report Opens the newest HTML report Generate Report Now Builds a report over all history and opens it Open Reports Folder Opens the reports\folderLaunch at Windows Startup Toggle auto-start on login (✓ = on) About Developer / company / license info Quit Fully stops the app
Do I need Python installed to run the
.exe? No. The executable bundles the Python runtime and all libraries. Any 64‑bit Windows 10/11 PC can run it with nothing installed. Python is only needed if you want to build the exe or run from source.
Open Settings from the tray menu (or edit config.json next to the exe).
| Setting | Meaning | Default |
|---|---|---|
| Connectivity check interval | Seconds between checks | 5 |
| Failed checks before marking offline | Debounce threshold | 2 |
| Auto-save HTML report every (hours) | Scheduled report cadence | 12 |
| Connection probe timeout | Seconds to wait per probe | 3 |
Monitoring changes apply automatically on the next check — no restart needed.
In Settings → Email Report:
- Tick “Email me a connectivity report every day”.
- Set the send time (24-hour
HH:MM). - Enter your SMTP details and the From / To addresses, then Save.
- Click Send Test Email to confirm it works.
Gmail example
| Field | Value |
|---|---|
| SMTP server | smtp.gmail.com |
| Port | 587 |
| Use STARTTLS | ✓ |
| Username | you@gmail.com |
| Password | a Google App Password (not your normal password) |
- Port 465 uses SSL automatically; 587 uses STARTTLS; 25 is plain.
- The password is masked on screen (toggle Show password to reveal). In
config.jsonit is stored masked (base64) — this hides it from casual viewing but is not encryption, so keep that folder private.
You only need this if you want to produce the executable (end users don’t).
Requirements: Windows + Python 3.10+.
git clone https://github.com/azeemgujjar/net-monitering.git
cd net-monitering
build.batThat’s it. build.bat will:
- install the dependencies (
pystray,Pillow) andPyInstaller, - generate the app icon (
app.ico), - produce
dist\InternetMonitor.exe— a single self-contained file.
Or run the steps manually:
python -m pip install -r requirements.txt
python make_icon.py
python -m PyInstaller --onefile --windowed --name InternetMonitor --icon app.ico --clean net_monitor_app.pygit clone https://github.com/azeemgujjar/net-monitering.git
cd net-monitering
python -m pip install -r requirements.txt
pythonw net_monitor_app.py :: tray app, no console
python net_monitor_app.py :: tray app, with a console for logsThe monitoring engine can also run headless from the command line:
python net_monitor.py :: run the monitor in the foreground (Ctrl+C to stop)
python net_monitor.py --report :: generate a report over all history and open it.
├── net_monitor_app.py # Desktop app (entry point): tray icon, dashboard,
│ # settings, About, email scheduler, auto-start
├── net_monitor.py # Engine: connectivity checks, event log, stats,
│ # HTML report generation, SMTP email
├── make_icon.py # Generates app.ico for the build
├── build.bat # One-click build -> dist/InternetMonitor.exe
├── requirements.txt # pystray, Pillow, pyinstaller
├── app.ico # Application icon
├── LICENSE # MIT
└── README.md
Files created at runtime (next to the script/exe, git-ignored):
config.json, events.jsonl, state.json, email_state.json,
monitor.log, reports/.
net_monitor.py is a self-contained, importable engine. net_monitor_app.py
drives it and adds the GUI. The app runs four cooperating threads:
| Thread | Responsibility |
|---|---|
| Main | Tkinter — owns all GUI; runs root.mainloop() |
| Monitor | net_monitor.run_monitor() — probes, logs, auto-reports |
| Daily scheduler — sends the report at the configured time | |
| Tray | pystray icon loop |
Tray-menu callbacks marshal any GUI work back onto the Tk thread via
root.after(...), because Tkinter is not thread-safe.
Key design points worth knowing before you change things:
- State is file-based.
events.jsonlis the source of truth; the dashboard and reports are both rebuilt from it viacompute_stats(), so their numbers always agree. - Frozen-path aware. When bundled, data files are written next to the
.exe(sys.executable’s folder), not PyInstaller’s temp dir. - Single instance. A named Windows mutex prevents duplicate tray icons.
- Auto-start is a per-user registry
Runentry — not a service, no admin.
- Add a config option: add it to
DEFAULT_CONFIGinnet_monitor.py(and_INT_CONFIG_KEYSif it’s an integer), then add a field to the Settings window innet_monitor_app.py. - Change probe targets: edit
PROBE_TARGETSinnet_monitor.py. - Restyle the HTML report: edit the
<style>block ingenerate_report(). - Restyle the dashboard: the color palette constants are at the top of
net_monitor_app.py.
After changing code, just re-run build.bat to produce a fresh exe.
- Tray icon doesn’t appear — it may be hidden in the “show hidden icons”
overflow (the
^arrow near the clock). Drag it onto the taskbar to pin it. - Email fails — use a provider App Password (Gmail/Outlook block normal passwords for SMTP), verify host/port, and use Send Test Email to see the exact error.
- SmartScreen warning on the exe — unsigned executables show a “Windows protected your PC” prompt: click More info → Run anyway. (Code signing requires a paid certificate.)
- Upgrading from the old headless version — if you previously ran
pythonw net_monitor.pyvia the Startup folder or Task Scheduler, remove that entry so two monitors don’t write to the same log; then use the app’s Launch at Windows Startup toggle instead.
Contributions are welcome! Please:
- Fork the repo and create a feature branch.
- Keep it dependency-light (standard library where possible).
- Test by running from source (
python net_monitor_app.py) and by building the exe (build.bat) before opening a PR. - Open a pull request describing the change.
Bug reports and feature requests via Issues are appreciated too.
Released under the MIT License — free to use, modify, and distribute. See LICENSE.
- Developer: Azeem Hassan — https://azeemhassan.com
- Company: StackOak Pvt Ltd — https://www.stackoaktech.com/
If you find this useful, a ⭐ on the repository is appreciated!