Skip to content

momenbasel/PureMac

Repository files navigation

PureMac

English | العربية | Español | 日本語 | 简体中文 | 繁體中文

PureMac

Reclaim your Mac.
Free, open-source uninstaller and cleaner for macOS. No subscription, no telemetry, no upsell.

Latest Release macOS 13.0+ Swift 5.9 MIT License Stars Downloads

Install - Why this exists - What it does - Permissions - Screenshots - Contributing


Install

brew install --cask puremac

Or download the signed, notarized .dmg from Releases and drag PureMac into /Applications. No Gatekeeper warnings, no quarantine workaround.

Build from source

brew install xcodegen
git clone https://github.com/momenbasel/PureMac.git
cd PureMac
xcodegen generate
xcodebuild -project PureMac.xcodeproj -scheme PureMac -configuration Release \
  -derivedDataPath build build
open build/Build/Products/Release/PureMac.app

Why this exists

Apple sells base-model Macs with 256 GB SSDs that you can't upgrade. The Mac mini, the Air, every entry-level MacBook Pro - the drive is soldered down. The next storage tier costs more than a midrange Windows laptop. Once you've paid it, every gigabyte you've already bought matters.

Most Mac cleaners are subscription apps that hide their disk usage behind a paywall, ship telemetry by default, and trade on FUD ("47 GB of junk detected!"). PureMac is the opposite:

  • One-time install. No subscription, no trial, no account.
  • No telemetry. It never phones home. It doesn't even know you exist.
  • Open source under MIT. Read the code, fork it, audit it.
  • Honest scans. "Junk" means actually-junk: cache directories the OS itself would purge, orphaned files left by apps you've already deleted, broken installer receipts, that 4 GB Xcode DerivedData blob from 2023.
  • Real uninstalls. Drag an app, see every preference plist, cache folder, container, launch agent and log file it dropped across your library, remove all of it at once.

What it does

App Uninstaller

Discovers everything in /Applications and ~/Applications, then uses a 10-level matching engine (bundle ID, team identifier, entitlements, Spotlight metadata, container discovery, company-name heuristics, partial path matches) to find every file the app dropped on your disk. Three sensitivity tiers - Strict, Enhanced, Deep - let you choose how aggressive that match is. Apple system apps are excluded from the uninstall list automatically.

Orphan Finder

Walks ~/Library and surfaces files left behind by apps that no longer exist on disk. The matcher compares against bundle identifiers and normalized names of every installed app, so a leftover ~/Library/Containers/com.foo.bar from an app you deleted in 2022 shows up clearly.

System Cleaner

Smart Scan runs every category in parallel. Each category is its own deliberate scanner:

  • System Junk - system caches, logs, temp files
  • User Cache - dynamically discovered, no hardcoded app list
  • AI Apps - Ollama and LM Studio logs, caches, opt-in history cleanup
  • Mail Files - downloaded mail attachments
  • Trash Bins - empties all bins, including external volumes
  • Large & Old Files - >100 MB or older than 1 year (never auto-selected)
  • Purgeable Space - reclaims APFS purgeable space via diskutil
  • Xcode Junk - DerivedData, Archives, simulator caches
  • Brew Cache - respects custom HOMEBREW_CACHE
  • Node Cache - npm, yarn classic, pnpm content-addressable store
  • Docker Cache - images, containers, build cache

Scheduled Cleaning

Optional. Configurable interval (hourly to monthly), with auto-clean threshold so background runs only fire when there's something meaningful to remove.

Permissions

PureMac needs Full Disk Access to read the locations macOS hides from every app by default - Mail downloads, Safari data, the TCC database, protected app containers. Without it, the cleanup categories miss roughly 70% of what they could find and app uninstalls leave behind everything in ~/Library/Containers.

The first-launch onboarding walks you through granting it with an animated preview of the exact toggle you need to flip. If you skip it, the dashboard surfaces a single-click "Set up" pill. If a cleanup fails because of a permission issue, PureMac opens System Settings, reveals its bundle in Finder so you can drag it into the FDA list, polls the permission state every second, and auto-retries the failed batch the moment you grant access. You never have to re-select anything.

What PureMac does not do:

  • It does not collect telemetry, crash reports, or usage analytics.
  • It does not require a network connection to operate.
  • It does not move data anywhere except the Trash and diskutil's APFS purge command.

Screenshots

Onboarding App Uninstaller
Onboarding App Uninstaller
System Junk Xcode Junk
System Junk Xcode Junk
User Cache
User Cache

Architecture

PureMac/
  Logic/Scanning/     - Heuristic scan engine, locations database, conditions
  Logic/Utilities/    - Structured logging
  Models/             - Data models, typed errors
  Services/           - Scan engine, cleaning engine, permission coordinator, scheduler
  ViewModels/         - Centralized app state
  Views/              - Native SwiftUI views
    Apps/             - App uninstaller views
    Components/       - Shared components (FDA demo, permission sheet, theme)
    Orphans/          - Orphan finder
    Settings/         - Native Form-based settings

Key components:

  • AppPathFinder - 10-level heuristic matching engine for discovering app-related files
  • Locations - 120+ macOS filesystem search paths
  • Conditions - 25 per-app matching rules for edge cases (Xcode, Chrome, VS Code, etc.)
  • PermissionCoordinator - Single source of truth for FDA prompts, polling, and post-grant retries
  • FullDiskAccessManager - TCC probe + registration; broad probe paths (Mail, Safari, Messages, AddressBook, Calendars) so macOS catalogs the bundle reliably
  • CleaningEngine - Symlink-resistant deletion with an allow-list, NSAppleScript-based admin escalation for root-owned items, NUL-separated path staging for xargs

Security

  • Symlink attack prevention: paths are resolved before validation, re-resolved immediately before unlink to close TOCTOU windows.
  • Allow-list cleaning: a path that doesn't sit inside an explicit safe-root is refused, even for the user-level pass.
  • Admin escalation is gated by a narrower allow-list (app bundles, package receipts, launch plists) than the normal cleaner — root-owned items can only be removed inside those roots.
  • System app protection: Apple's bundles cannot be uninstalled, regardless of selection.
  • All destructive operations require explicit confirmation by default. The toggle that disables that confirmation is buried in Settings.

If you find a vulnerability, please open a private security advisory rather than a public issue.

Contributing

Pull requests welcome. See CONTRIBUTING.md.

Especially welcome:

  • Per-category size and date filter presets
  • Wider XCTest coverage for AppState and the scan engine
  • Translations beyond the current set (en, ar, es, ja, pt-BR, zh-Hans, zh-Hant)
  • App icon design

Acknowledgments

License

MIT. See LICENSE. Use it, fork it, ship it under your own name if you want - the only thing the license asks is that the notice stays.

About

Free, open-source macOS cleaner. CleanMyMac alternative with zero telemetry. Native SwiftUI, scheduled auto-cleaning, Xcode/Homebrew/system cache cleanup. MIT licensed.

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Packages

 
 
 

Contributors