PureMac macOS Cleaner
Skill by ara.so — Daily 2026 Skills collection.
PureMac is a free, native SwiftUI macOS application that cleans system junk, user caches, Xcode derived data, Homebrew caches, mail attachments, and purgeable APFS space. It is a privacy-respecting, open-source alternative to CleanMyMac X with no telemetry, no subscriptions, and no network calls.
Install
Homebrew (recommended)
Direct Download
Download the latest .app from Releases, unzip, and drag to /Applications.
Build from Source
Requirements: macOS 13.0+, Swift 5.9, Xcode 15+.
Project Structure
Core Concepts
Clean Categories
PureMac operates on named categories, each mapping to specific filesystem paths:
Large & Old Files are never auto-selected — the user must explicitly choose items before cleaning.
Working with the Codebase
Adding a New Clean Category
- Define the category in
CleanCategory.swift:
- Add scanning logic in
ScannerService.swift:
- Add cleaning logic in
CleanerService.swift:
Scheduled Auto-Cleaning
Configure via Settings → Schedule tab. Intervals: hourly, 3h, 6h, 12h, daily, weekly, biweekly, monthly.
Enable scheduling programmatically:
Purgeable Space (APFS Snapshots)
PureMac uses tmutil to delete local Time Machine snapshots — this is the only operation requiring elevated privileges:
Xcode Cache Paths
Scan these and safely delete their contents without removing the directories themselves.
SwiftUI View Patterns
Scan Progress View
File Inspector (Click-to-Inspect)
Configuration (AppStorage Keys)
All preferences are stored in UserDefaults via @AppStorage:
Read/write from anywhere:
Building & Testing
Contributing
- Fork and clone the repo.
- Run
xcodegen generateto create the.xcodeproj. - Create a feature branch:
git checkout -b feature/gradle-cache-cleaning - Follow existing patterns in
ScannerService/CleanerService. - Never add network calls, analytics SDKs, or telemetry of any kind.
- Large & Old Files must never be auto-selected for deletion.
- Open a PR against
main.
See CONTRIBUTING.md for full guidelines.
Troubleshooting
Safety Guarantees
- Never deletes system-critical files or application bundles.
- Only removes caches, logs, temp files, and user-selected items.
- Large & Old Files require explicit user selection before deletion.
- Purgeable operations target only APFS Time Machine snapshots — not free space.
- All filesystem operations use
FileManager.removeItem(at:)— norm -rfshell calls for regular cleaning.


