Periphery logo

Eliminate Unused Swift Code

Periphery analyzes Swift projects to identify unused code

Start Your Free Trial Now

  • No signup or credit card required
  • Quick & simple installation
  • No time restriction

Install & run – it's that simple!

Get Started

Unused Code Is a Burden

Are your refactorings complicated by awkward code that might no longer be needed?
How many minutes do you waste every day reading unused code?

As any good chef will attest to, keeping your workspaces clean and tidy is fundamental. We believe the same applies to software - keeping your projects free of unused code is fundamental practice of professional software development.

Take pride in your work. Keep it clean.

Read our Manifesto

Comprehensive Analysis

Periphery can identify a wide range of unused declarations in your project.
Swift alternative logo
  • Classes, structs & protocols
  • Functions & properties
  • Enums & individual cases
  • Type aliases & associated types

More than a simple reference checker…

Periphery applies advanced analytical heuristics to identify unused code that a simple reference checker would have no hope of finding.

To Periphery code is more than a static graph of nodes and edges; Periphery mutates your application's structure in memory to detangle a multitude of self-referential, semantic & redundant references.

Redundant Protocols

Redundant protocol conformance is a prime example of Periphery's analytical power.

................
'Greeter' is unused
protocol Greeter { func greet() } class MyGreeter: Greeter { func greet() { print("Hello, World!") } } let greeter = MyGreeter() greeter.greet()

Periphery can identify protocols that are conformed to, but which are not directly used in a specialization. In this example, Greeter can be removed.

These situations can be hard to identify with the naked eye, especially if the protocol is conformed to by multiple classes spanning multiple files.

Learn more about protocol analysis

Assign-only Properties

Identification of assign-only properties is perfect for rooting out unused dependencies.

 
 
 
 
 
.................
'presenter' is unused
class Greeter { static func make() -> Self { return self.init(presenter: inject()) } let presenter: Presenter init(presenter: Presenter) { self.presenter = presenter } func greet() { print("Hello, World!") } }

Periphery can identify properties that are assigned a value, but which are never read from.

Often when removing old features the focus is on deleting functions, properties once used by those functions can easily slip under the radar.

If you do dependency injection via the constructor, you'll love this feature!

Learn more about assign-only properties

Xcode Integration

Xcode integration example

Periphery outputs results in a format Xcode understands. Unused code is highlighted as warnings, just like you're accustomed to with other build warnings.

Integration is as simple as creating an Aggregate build target with a Run Script phase.

Xcode Integration Guide

We Command Line Junkies
Periphery is primarily a command line driven tool, rest assured you can use it without ever touching a mouse!

Your Code Is Safe

The safety of your intellectual property is paramount.

That's why Periphery performs 100% of its analysis locally, on your computer. That means no remote services, your code simply never leaves your computer.

Learn more about validating the security of Periphery

Try Before You Buy

Periphery runs in trial mode out of the box.
No signup or credit card required, simply install and get started.

Results for 25% of source files per build target

Try it on as many projects as you like

No time restriction

How much unused code is lurking in your project?

Indie Team

SALE
$49.95
$34.95

For team of 1 or 2 developers
1 year license
  •  Email Support
  •  Use in Continuous Integration

Small Team

SALE
$199
$139

For team of 3-5 developers
1 year license
  •  Email Support
  •  Use in Continuous Integration

Medium Team

SALE
$499
$349

For team of 6-10 developers
1 year license
  •  Email Support
  •  Use in Continuous Integration

Large Team

SALE
$1,199
$839

For team of 11-20 developers
1 year license
  •  Email Support
  •  Use in Continuous Integration

Pricing Explained  

Pricing is based on the number of developers in your product team working with Swift, not the number of developers that will directly use Periphery. Team size is a strongly correlated to the rate of change within your product, and thus the rate at which your product will accumulate unused code.

Need a Larger License?

Get in touch, we'll accommodate your needs.

Contact Us