A terminal-native macOS system monitor, cleaner and optimizer — a free, private, open-source CCleaner alternative built for developers. 100% local, zero telemetry.
Install • Quick Start • Screenshots • Sentinel • Features • Commands • SoClose
macmon is a free, open-source Mac system monitor and cleaner that runs entirely in your terminal. Think CCleaner Pro + Activity Monitor + Security Scanner + Docker Manager, reimagined as one fast CLI with a live TUI dashboard — purpose-built for developers who live in the shell.
If you have ever searched for "how to clean my Mac", "free CCleaner alternative for macOS", "free up disk space on Mac", "why is my Mac slow", or "macOS system monitor CLI" — this is the tool, and it never phones home.
30 commands · 18 modules · Live dashboard · MACMON-SENTINEL always-on watchdog · Keyboard shortcuts that execute real actions · Autopilot daemon · Thermal management · Security & malware scanner · Docker manager · 100% local, zero telemetry
- Free & open source (MIT) — no license, no account, no upsell, no cloud.
- Private by design — everything runs locally; nothing is uploaded, ever.
- Developer-first cleanup — reclaims
node_modules, stale venvs, Docker cache, Xcode/DerivedData, npm/pip/brew caches with safety guards. - Safe deletes — moves to Trash by default and never silently escalates to permanent deletion.
- One binary of a habit — monitor, clean, secure and keep your Mac fast from a single CLI.
macmon is macOS-first (that is where every feature works), with a cross-platform core so the portable tools also run on Windows and Linux. On other platforms, macOS-only commands degrade gracefully with a clear "requires macOS" message instead of crashing.
This is not a claim -- it is enforced. CI runs on macOS, Ubuntu and Windows (Python 3.11 and 3.13) on every push: it imports all 18 modules, smoke-tests the portable commands, and asserts that every macOS-only command exits cleanly with a "requires macOS" notice off-mac.
| Feature | macOS | Windows | Linux |
|---|---|---|---|
ps / kill / suspend / nice (processes) |
✅ | ✅ | ✅ |
disk / bigfiles / dupes |
✅ | ✅ | ✅ |
clean (temp / cache / logs / dev caches) 1 |
✅ | ✅ | ✅ |
gc (node_modules, venvs, docker, caches) 2 |
✅ | ✅ | ✅ |
network / flush-dns |
✅ | ✅ | ✅ |
docker management |
✅ | ✅ | ✅ |
health score |
✅ | ✅ (core checks) | ✅ (core checks) |
sentinel monitor + auto-remediation |
✅ | ✅ (schtasks) | ✅ (cron) |
Live dashboard (TUI) |
✅ | ✅ | ✅ |
security (pf, SIP, FileVault, Gatekeeper) |
✅ | -- | -- |
privacy / startup / uninstall / auto / focus |
✅ | -- | -- |
1 Core paths only (temp, caches, logs, dev caches) route through the
cross-platform layer. clean --browsers still uses macOS browser-profile paths
(~/Library/...), so it finds nothing on Windows/Linux today.
2 Core scanning (node_modules, venvs, __pycache__, Docker, npm /
pnpm / yarn / bun) is cross-platform. The pip cache path is macOS-only today, so
that one category comes back empty elsewhere.
On Windows/Linux install by cloning + pip install -r requirements.txt, then
python macmon.py. The macOS install.sh sets up the macmon shortcut on
macOS/Linux.
|
System health, scored /100 |
One-pass junk & cache cleaner |
|
Security & malware audit |
Categorized process monitor |
Above: the MACMON-SENTINEL tactical console (top of page). All output is real, rendered live — no mockups.
|
Full-screen TUI with real-time monitoring:
|
Execute real actions directly from the dashboard:
|
|
|
|
|
|
Background rules engine:
|
|
|
|
git clone https://github.com/SoCloseSociety/macmon.git
cd macmon
bash install.shThis will:
- Check Python 3.11+
- Create a venv at
~/.macmon/venv - Install dependencies (
rich,psutil,typer,send2trash,xxhash) - Create
/usr/local/bin/macmonwrapper - Initialize config at
~/.macmon/config.toml
bash build_dmg.sh
open dist/macmon.dmg# Launch the live dashboard
macmon
# Full system clean
macmon clean --all -y
# Dev garbage collector
macmon gc --all -y
# Security audit
macmon security
# Health check + auto-fix
macmon health --fix
# Kill zombies & orphans
macmon sweep -y
# Purge RAM
macmon purge
# Start autopilot daemon
macmon auto --start
# Focus mode
macmon focus
# All commands
macmon --help| Command | Description |
|---|---|
macmon |
Live dashboard |
macmon ps |
Process list with categories |
macmon kill <target> |
Kill process |
macmon suspend / resume <target> |
Suspend / resume process |
macmon nice <target> <val> |
Renice process |
macmon quit / restart <app> |
Graceful quit / restart app |
macmon sweep |
Kill zombies, orphans, stale locks |
macmon ports |
Port manager |
macmon clean --scan |
Preview cleanable junk |
macmon clean --all -y |
Full system clean |
macmon clean --browsers |
Browser cleaner |
macmon gc --scan |
Preview dev garbage |
macmon gc --all -y |
Full dev GC |
macmon privacy --scan |
Preview privacy traces |
macmon privacy --full -y |
Wipe all traces |
macmon health |
Health check /100 |
macmon health --fix |
Auto-fix safe issues |
macmon startup --list |
List startup items |
macmon startup --audit |
Audit suspicious items |
macmon uninstall <app> |
Uninstall + leftover cleanup |
macmon dupes <path> |
Find duplicate files |
macmon bigfiles |
Find large files |
macmon disk |
Disk usage analyzer |
macmon network |
Network connections |
macmon flush-dns |
Flush DNS cache |
macmon security |
Security audit /100 |
macmon security --block-ip <ip> |
Block IP via pf firewall |
macmon security --quarantine <proc> |
Kill + block process |
macmon docker |
Docker overview |
macmon docker --prune -y |
Docker full cleanup |
macmon docker --scan |
Docker security audit |
macmon auto --start / --stop |
Start / stop autopilot daemon |
macmon focus / restore |
Focus mode on / off |
macmon purge |
Purge inactive RAM |
macmon report |
Session report |
macmon config --show / --edit |
View / edit config |
macmon sentinel --install |
Arm the always-on light monitor |
macmon sentinel |
Tactical console snapshot |
macmon sentinel --watch |
Live tactical console |
macmon sentinel --force-clean |
Manual override: scan then clean |
macmon sentinel --test-notify |
Test notification (shows the macmon icon) |
macmon sentinel --enable-auto |
Enable safe auto-remediation (unload idle ollama models + RAM purge) |
macmon sentinel --enable-auto --aggressive |
Also auto-close idle AI sessions |
macmon sentinel --disable-auto |
Disable all auto-remediation (back to notify-only) |
macmon sentinel --trim |
Close idle AI sessions now |
macmon sentinel --unload-ollama |
Unload idle ollama models now (they reload on demand) |
macmon sentinel --setup-purge |
Grant passwordless purge via sudoers so auto-purge runs unattended |
An ultra-light watchdog that keeps the Mac operational without you watching it.
- Near-zero cost: a single-shot sampler fires every 60s via a LaunchAgent, measures in ~0.5s, appends one compact JSON line, then exits. No resident process between samples (~0.1% average CPU, ~20 MB peak per sample).
- Precise: tracks CPU, RAM, swap, load, disk, network RTT, the top CPU process, and the AI-agent fleet (Claude Code / codex / MCP counts + RSS) so forgotten sessions are surfaced, not rediscovered in a crisis.
- Hidden RAM hogs, surfaced: it also tracks the two big ones nothing else
shows you -- loaded ollama models (
ollama ps, multi-GB and easy to forget) and the Docker/Colima VM footprint. The VM is notify-only: the Sentinel warns abovevm_gband never stops it on its own. - Auto-interaction: threshold alerts fire native macOS notifications (swap high, memory pressure, runaway process, network saturated, low disk, AI fleet too large), each with a cooldown.
- Auto-remediation (safe escalation): nothing is automatic until you opt in.
Remediation only fires when memory pressure is genuinely critical (RAM above
ram_criticaland swap aboveswap_critical_gb), and the Sentinel always notifies what it did:- Level 1a --
auto_unload_ollama(non-destructive): unloads idle ollama models when RAM is critical and they hold at leastollama_gb. Never touches a model mid-inference (a busy runner is detected and skipped), and models reload automatically on the next request. Turned ON by--enable-auto. - Level 1b --
auto_purge(non-destructive, macOS only): frees inactive RAM viapurge. Turned ON by--enable-auto. - Level 2 --
auto_trim_fleet(opt-in): closes idle AI coding sessions (Claude Code) beyond a configurable minimum (fleet_keep), protecting the most recently active ones so the session you are using is never touched. A session must be idle foridle_samplessamples (~10 min) first, and sessions are resumable (--resume). Requiresmacmon sentinel --enable-auto --aggressive. - Turn everything back off with
macmon sentinel --disable-auto(notify-only). - Manual levers any time:
macmon sentinel --trimcloses idle sessions now,macmon sentinel --unload-ollamaunloads idle ollama models now.
- Level 1a --
Heads-up:
--enable-autoenables levels 1a and 1b. That means once RAM is critical, macmon may unload your loaded ollama models without asking. It is non-destructive (they reload on demand, and never mid-inference), but if you want notifications only, do not run--enable-auto.
purge requires root, so unattended auto_purge needs sudo without a password
prompt. macmon sentinel --setup-purge sets that up explicitly, and only that:
- It writes
/etc/sudoers.d/macmon-purgecontaining exactly one line:<your-user> ALL=(root) NOPASSWD: /usr/sbin/purge - The snippet is validated with
visudo -cbefore being installed (a malformed sudoers file would breaksudosystem-wide), then installed0440. - The grant is scoped to that single binary --
/usr/sbin/purgeand nothing else. It is not blanket passwordless sudo. - Without it,
auto_purgeis simply skipped and notifications still fire. It is optional. - Revoke at any time:
sudo rm /etc/sudoers.d/macmon-purge - Manual override: force levers when you must push the system --
--force-purge,--force-clean,--force-focus,--pause/--resume. - Branded notifications: alerts pop up carrying the macmon icon (not the
generic Script Editor icon) via a tiny bundled notifier app. Try it with
macmon sentinel --test-notify.
macmon sentinel --install # arm it (LaunchAgent, 60s sampler)
macmon sentinel # tactical snapshot with gauges + sparklines
macmon sentinel --watch # live console
macmon sentinel --status # agent + config status
macmon sentinel --log # recent alertsConfig lives in ~/.macmon/sentinel.conf (JSON). Any key you omit falls back to
the default below.
| Key | Default | Meaning |
|---|---|---|
swap_used_gb |
6.0 |
Alert when swap usage exceeds this many GB |
ram_pct |
92.0 |
Alert when RAM usage exceeds this percentage |
proc_cpu |
95.0 |
Alert when a single process exceeds this CPU% (runaway) |
rtt_ms |
400.0 |
Alert when network round-trip time exceeds this |
disk_free_gb |
15.0 |
Alert when free disk space drops below this |
ai_fleet |
12 |
Alert when the AI-agent fleet exceeds this many processes |
ping_every |
5 |
Ping only every Nth sample (spares a metered link) |
ollama_gb |
2.0 |
Warn when idle ollama models hold more than this |
vm_gb |
4.0 |
Warn when a Docker/Colima VM holds more than this (notify-only) |
auto_purge |
false |
Level 1b: purge inactive RAM when critical (macOS only) |
auto_unload_ollama |
false |
Level 1a: unload idle ollama models when critical |
auto_trim_fleet |
false |
Level 2: close idle AI sessions when critical |
fleet_keep |
4 |
Always keep at least this many AI sessions alive |
ram_critical |
90.0 |
Remediation triggers above this RAM% ... |
swap_critical_gb |
8.0 |
... and above this swap usage, never on one alone |
idle_samples |
10 |
A session must be idle this many samples (~10 min) before trimming |
macmon.py CLI router (typer, 30 commands)
modules/
dashboard.py Live TUI (rich) — 12 panels, keyboard shortcuts
sentinel.py MACMON-SENTINEL: 60s sampler, alerts, auto-remediation
processes.py Process manager, sweep, ports
cleaner.py System cleaner (junk, browsers, apps)
gc.py Dev garbage collector
security.py Security scanner & IP blocking
docker_mgr.py Docker container/image/volume management
autopilot.py Daemon, thermal rules, security rules, focus mode
health.py Health check /100 & reports
privacy.py Privacy traces wiper
startup.py Startup/login items manager
uninstaller.py App uninstaller with leftover detection
duplicates.py Duplicate file finder (xxhash + SHA-256)
disk.py Disk analyzer & big file finder
network.py Network monitor
config.py TOML config manager
platform_compat.py Cross-platform layer (macOS / Windows / Linux paths, require_os)
utils.py Shared utilities, SQLite DB, logging
Config lives at ~/.macmon/config.toml:
macmon config --editKey sections: dashboard, thresholds, cleaner, privacy, gc, focus_mode, notifications, autopilot.
MIT — see LICENSE. Free forever, for any use.
Is macmon really free? Yes — MIT licensed, no account, no telemetry, no paid tier.
Does it send my data anywhere? No. Everything runs locally on your Mac. There is zero network telemetry.
Is it a CCleaner alternative for Mac? Yes — it covers the same ground (caches, logs, temp, browser data, privacy traces) plus developer-specific cleanup (node_modules, venvs, Docker, Xcode) and safe Trash-first deletes.
Will it delete something important? Deletes move to the Trash by default and never silently escalate to permanent removal. Destructive categories are opt-in.
Which macOS versions? macOS 12 (Monterey) and newer, on Apple Silicon and Intel. Python 3.11+.
Keywords: mac cleaner · macOS system monitor · clean my Mac · free CCleaner alternative macOS · free up disk space Mac · why is my Mac slow · macOS terminal system cleaner · developer Mac tools · node_modules cleaner · Docker disk cleanup Mac · macOS privacy cleaner · macOS malware scanner CLI · Activity Monitor alternative · Mac optimizer open source · Python Typer Rich TUI · zero telemetry mac utility
Built with purpose by SoClose — Digital Innovation Through Automation & AI