Swift/ SourceCleaner

SourceCleaner is a macOS app that helps you find and clean up likely unused Swift code in real projects, without losing control of your source.
It scans your project, builds a declaration/reference map, and highlights symbols and files that appear unused. You can then review each result in an integrated code editor, inspect usage locations, and apply cleanup actions selectively or in bulk.

SourceCleaner is designed for practical cleanup work: it understands Swift source structure, checks Xcode project membership, reads storyboard/xib custom class references, and applies safety rules to reduce false positives for runtime-driven code.

How SourceCleaner Works

Select or drag a project folder into the app.
SourceCleaner scans Swift files and builds an outline of declarations and references.
It computes usage counts per symbol and flags likely unused declarations.
It identifies likely unused files and Swift files that exist on disk but are not part of an Xcode project.
You review results in the navigator/editor and choose cleanup actions: comment out, add MARK comments, delete declarations, or delete files (optionally removing .xcodeproj references).