๐น Clean, uninstall, analyze, optimize, and monitor your Mac. Free open-source CLI, plus a native Mac app.
Prefer a native app? Mole for Mac brings cleanup, app management, maintenance, disk maps, and live status into one lightweight, VoiceOver-ready app. It is $19 once and covers 2 Macs, with lifetime updates and a 14-day refund. The license moves with you when you replace a Mac. Download and try it. The CLI stays free and open source.
- All-in-one toolkit: Combines CleanMyMac, AppCleaner, DaisyDisk, and iStat Menus in a single binary
- Deep cleaning: Removes caches, logs, leftovers, and orphaned app data to reclaim gigabytes of space
- Smart uninstaller: Removes apps plus launch agents, preferences, and hidden remnants
- Disk insights: Visualizes usage, finds large files, rebuilds caches, and refreshes system services
- Live monitoring: Shows real-time CPU, GPU, memory, disk, and network stats
Install via Homebrew
brew install moleIf Homebrew no longer supports your macOS version, use the script below instead.
Or via script
curl -fsSL https://raw.githubusercontent.com/tw93/mole/main/install.sh | bashMole is built for macOS. An experimental Windows version lives in the windows branch.
Run
mo # Interactive menu
mo clean # Deep cleanup + already-uninstalled app leftovers
mo uninstall # Remove installed apps + their leftovers
mo optimize # Refresh caches & services
mo analyze # Visual disk explorer (or 'mo analyse')
mo status # Live system health dashboard
mo purge # Clean project build artifacts
mo installer # Find and remove installer files
mo touchid # Configure Touch ID for sudo
mo completion # Set up shell tab completion
mo update # Update Mole
mo update --nightly # Update to latest unreleased main build, script install only
mo remove # Remove Mole from system
mo --help # Show help
mo --version # Show installed versionPreview safely
mo clean --dry-run
mo uninstall --dry-run
mo optimize --dry-run
mo purge --dry-run
mo installer --dry-run
mo history
mo history --json
mo clean --dry-run --debug # Preview + detailed logs
mo optimize --whitelist # Manage protected optimization rules
mo clean --whitelist # Manage protected caches
mo purge --paths # Configure project scan directories
mo analyze /Volumes # Analyze external drives only
mo analyze /private/tmp # Review user-owned temporary directoriesSelections made with mo clean --whitelist persist in ~/.config/mole/whitelist.
Other install options
To install a specific release, pass any tag from the releases page, with or without its leading V. To track the development branch instead, pass main:
curl -fsSL https://raw.githubusercontent.com/tw93/mole/main/install.sh | bash -s -- 1.51.0
curl -fsSL https://raw.githubusercontent.com/tw93/mole/main/install.sh | bash -s -- mainmain installs unreleased code from the default branch, so expect rough edges. latest still works as a legacy alias for main; despite the name it does not install the newest stable release.
The script normally installs to /usr/local/bin, which may ask for an administrator password. Install into a user-owned directory if you want future mo update runs to stay password-free:
mkdir -p "$HOME/.local/bin"
curl -fsSL https://raw.githubusercontent.com/tw93/mole/main/install.sh | bash -s -- --prefix "$HOME/.local/bin"
export PATH="$HOME/.local/bin:$PATH"Add the same PATH export to ~/.zshrc or your shell profile for new terminals. Mole updates the installation you invoked, so it keeps using this directory. Commands that change system-owned files may still request administrator access.
Prefer a walkthrough? Watch the Mole tutorial video by PAPAYA ้ป่ ฆๆๅฎค.
Mole can remove files, so it validates paths, protects shared and system-owned locations, and asks for confirmation when an action needs it. When Mole cannot prove an item is safe to change, it skips or refuses it.
clean,uninstall,purge,installer, andremovecan delete files. Review them with--dry-runfirst, and add--debugwhen needed.mo analyzemoves selected items to Trash after confirmation.- Cleanup activity is recorded in
~/Library/Logs/mole/operations.log; review it withmo historyor disable it withMO_NO_OPLOG=1. - Protect caches with
mo clean --whitelist, or maintenance items withmo optimize --whitelist.
Review SECURITY.md and SECURITY_AUDIT.md for reporting guidance, safety boundaries, and current limitations.
The examples below are shortened. Available items, sizes, and skip reasons depend on your Mac.
mo clean reviews known-safe caches, logs, temporary files, developer artifacts, and leftovers from apps that are no longer installed. Use mo clean --dry-run to preview eligible paths, and mo clean --whitelist to protect caches you want to keep.
$ mo clean
Clean Your Mac
โ Apple Silicon | Free space: 219.0GB
โค User essentials
โ User app cache ยท 18 items, 2.4GB
โ User app logs ยท 7 items, 12.8MB
โ Trash ยท emptied, 9 items
โค App caches
โ App Store cache ยท 8 items, 248.5MB
โค Browsers
โ Safari cache ยท 24 items, 642.1MB
โ Chrome cache ยท 31 items, 1.2GB
โค Developer tools
โ npm cache ยท cleaned
โ pnpm cache ยท skipped (pnpm busy)
โ Xcode runtime volumes ยท removed 2, 3 in use
======================================================================
Cleanup complete
Tracked cleanup: 4.5GB | Items cleaned: 97 | Categories: 4
Free space: 223.5GB (+4.5GB)
======================================================================
mo uninstall removes an installed app together with related files that Mole can tie back to that app. It keeps shared data when another installed copy still uses it. Use mo uninstall --dry-run to review the plan. If the app is already gone, use mo clean to look for leftovers.
$ mo uninstall
Select Apps to Remove 1/3 selected
โค โ Photoshop 2024 4.20GB | 2mo ago
โ IntelliJ IDEA 2.80GB | 3d ago
โ Premiere Pro 3.40GB | 2w ago
Files to be removed:
โ Photoshop 2024, 12.80GB
โ /Applications/Adobe Photoshop 2024/Adobe Photoshop 2024.app
โ ~/Library/Application Support/Adobe/Adobe Photoshop 2024
โ ~/Library/Preferences/com.adobe.Photoshop.plist
======================================================================
Uninstall complete
Removed 1 app, freed 12.80GB: Photoshop 2024
======================================================================
mo optimize runs bounded maintenance for supported Finder, network, database, and macOS services. Tasks that are unnecessary, unsafe at the moment, or unavailable are skipped with a reason. Use mo optimize --dry-run to preview the pass and mo optimize --whitelist to exclude tasks or path patterns.
$ mo optimize
Optimize
โ System 18/32 GB RAM | 616/926 GB Disk | Uptime 6d
PERFORMANCE DIAGNOSIS
โ No sustained high-CPU bottleneck detected
โค DNS & Spotlight Check
โ DNS cache flushed
โ Spotlight index verified
โค Finder Cache Refresh
โ QuickLook thumbnails refreshed
โ Icon services cache rebuilt
โค Database Optimization
โ Close these apps before database optimization: Safari
โค Disk Health
โ Disk verify skipped (set MOLE_ENABLE_DISK_VERIFY=1 to enable)
======================================================================
Optimization Complete
Applied 3 optimizations
14 unchanged | 3 skipped | 1 unavailable
======================================================================
Path patterns work too, so you can keep a long-lived mounted disk image around, for example /Volumes/mail, without it showing up as a detach candidate.
mo analyze opens a terminal disk explorer. It supports arrow keys and Vim navigation, filtering, multi-selection, Finder preview, and confirmed moves to Trash. External drives are skipped from the default overview; inspect them with mo analyze /Volumes or a specific mount path. Use mo analyze /private/tmp to review user-owned temporary files without turning them into automatic cleanup targets.
$ mo analyze
Analyze Disk (302.1GB free)
Select a location to explore:
โถ 1. โโโโโโโโโโโโโโโโโโโโโโโโ 47.9% | Home 75.4GB
2. โโโโโโโโโโโ 22.0% | User Library 34.6GB
3. โโโโโโโ 14.2% | Applications 22.4GB
4. โโโโโ 10.7% | System Library 16.9GB
5. โโโ 5.2% | Old Downloads (90d+) 8.2GB >3mo
mo status is a read-only dashboard for hardware, system pressure, disk activity, network traffic, power, and processes.
$ mo status
Mole Status Health โ 92 MacBook Pro ยท M4 Pro ยท 32GB ยท macOS 26
โ CPU โฆ Memory
Total โโโโโโโโโโโโโโโโโโโ 45.2% Used โโโโโโโโโโโโโโโโโโ 58.4%
Load 0.82 / 1.05 / 1.23 (8 cores) Total 18.7 / 32.0 GB
Core 1 โโโโโโโโโโโโโโโโโโโ 78.3% Free โโโโโโโโโโโโโโโโโโ 41.6%
Core 2 โโโโโโโโโโโโโโโโโโโ 62.1% Avail 13.3 GB
โค Disk โก Power
Used โโโโโโโโโโโโโโโโโโโ 67.2% Level โโโโโโโโโโโโโโโโโโ 100%
Free 156.3 GB Status Charged
Read โฎโฏโฏโฏโฏ 2.1 MB/s Health Normal ยท 423 cycles
Write โฎโฎโฎโฏโฏ 18.3 MB/s Temp 58ยฐC ยท 1200 RPM
โ
Network โถ Processes
Down โโโโโโโโโโโโโโโ
โ 0.54 MB/s Code โฎโฎโฎโฎโฏ 42.1%
Up โโโโโโโโโโโโโโโโ 0.02 MB/s Chrome โฎโฎโฎโฏโฏ 28.3%
Proxy HTTP ยท 192.168.1.100 Terminal โฎโฏโฏโฏโฏ 12.5%
The health score combines CPU, memory, disk capacity, SMART status, I/O, thermals, battery state, and uptime, with color-coded ranges. Press k to toggle the cat, c to cycle the number of CPU cores shown, or q to quit. Display preferences are saved.
JSON, NDJSON, and process alerts
mo analyze --json ~/Documentsreturns a one-time disk report as JSON.mo status --jsonreturns a one-time status snapshot as JSON.mo status | jq '.health_score'switches to JSON automatically when output is piped.mo status --watch --interval 2sstreams newline-delimited JSON from a warm collector.mo history --jsonreturns cleanup activity as JSON.
$ mo analyze --json ~/Documents
{
"path": "/Users/you/Documents",
"overview": false,
"entries": [
{ "name": "Library", "path": "...", "size": 80939438080, "is_dir": true }
],
"large_files": [
{ "name": "backup.zip", "path": "...", "size": 8796093022 }
],
"total_size": 168393441280,
"total_files": 42187
}
$ mo status --json
{
"host": "MacBook-Pro",
"health_score": 92,
"cpu": { "usage": 45.2, "logical_cpu": 8 },
"memory": { "total": 34359738368, "used": 20078972109, "used_percent": 58.4 },
"disks": [],
"uptime": "3d 12h 45m"
}
Status also supports read-only alerts for processes that stay above a CPU threshold. Use --proc-cpu-threshold, --proc-cpu-window, or --proc-cpu-alerts=false to tune or disable them.
mo purge finds rebuildable project artifacts such as node_modules, target, .build, build, and dist. It groups artifacts by project and permanently deletes only the items you confirm. Artifacts with file activity in the last 7 days, or activity Mole cannot verify, are unselected by default. Mole uses fd when available and falls back to find.
Purge example output
$ mo purge
Purge Project Artifacts
Select Artifacts to Purge, 6.00GB, 2 selected
โค โ โ ~/Projects/website 3.80GB | node_modules | 28d
โ โ ~/Projects/website 186MB | dist | <1d
โ โ ~/Projects/rust-app 2.20GB | target | 2mo
โ โ ~/Projects/rust-app 22MB | dist | <7d
======================================================================
Purge complete
Space freed: 6.00GB | Items: 2 | Free: 223.5GB
======================================================================
Custom Scan Paths
Run mo purge --paths to configure scan directories, or edit ~/.config/mole/purge_paths directly:
~/Documents/MyProjects
~/Work/ClientA
~/Work/ClientBWhen custom paths are configured, Mole scans only those directories. Otherwise, it uses defaults like ~/Projects, ~/GitHub, and ~/dev.
mo installer finds DMG, PKG, MPKG, ISO, XIP, and installer ZIP files in Downloads, Desktop, Homebrew caches, iCloud, Mail, Telegram, and other supported locations. Each item shows its size and source before removal. Use mo installer --dry-run to preview the plan.
Installer example output
$ mo installer
Select Installers to Remove, 3.83GB, 5 selected
โค โ Photoshop_2024.dmg 1.20GB | Downloads
โ IntelliJ_IDEA.dmg 850.6MB | Downloads
โ Illustrator_Setup.pkg 920.4MB | Downloads
โ PyCharm_Pro.dmg 640.5MB | Homebrew
โ Acrobat_Reader.dmg 220.4MB | Downloads
โ AppCode_Legacy.zip 410.6MB | Downloads
======================================================================
Installers cleaned
Removed 5 installers, freed 3.83GB
======================================================================
Raycast and Alfred setup
Install five launchers for Clean, Uninstall, Optimize, Analyze, and Status:
curl -fsSL https://raw.githubusercontent.com/tw93/Mole/main/scripts/setup-quick-launchers.sh | bashThe script adds Raycast commands and, when Alfred preferences are present, matching Alfred workflows with the keywords clean, uninstall, optimize, analyze, and status.
Raycast needs one manual setup:
- Open Raycast Settings > Extensions > Script Commands.
- Add
~/Library/Application Support/Raycast/script-commandsas a script directory. - Run Reload Script Directories in Raycast.
The launchers auto-detect Terminal, iTerm2, Alacritty, kitty, WezTerm, Ghostty, Hyper, WindTerm, and Warp. Set MO_LAUNCHER_APP=<name> to choose one; you can also run Mole directly in Kaku.
Thanks to everyone who helped build Mole. Go follow them. โค๏ธ
Real feedback from users who shared Mole on X.
- Getting Mole for Mac is the most direct way to support Mole's development.
- If Mole helped you, give it a star, share it, or open an issue or PR.
- I have two cats, TangYuan and Coke. If you think Mole delights your life, you can feed them canned food ๐ฅฉ.
Mole is open source under GPL-3.0; see LICENSE. A version you modify and share stays under the same license. If you fork Mole into another product, please give it a different name and credit Mole as the source.
Mole for Mac is a separate proprietary app. Mole is here for the long run.

