Catch visual regressions with zero-code.

PreviewLens captures and compares your #Previews in watch mode, notifying both you and your AI agent when regressions occur.

No test harness required - snapshots are created when you build
Apple platforms - iOS, macOS, watchOS, frameworks, Swift packages
Built for review - choose between side-by-side or overlay diffs
Gallery view - view all previews, filter and sort
Control the noise - thresholds + dynamic masks
Built for humans and AI - UI & file config + agent-readable results

Build. Snapshot. Diff. Approve.

What PreviewLens does

Preview-native snapshots on build, clear diffs for review, and control over noise.

Preview-native snapshots on build

As soon as you build, PreviewLens renders and snapshots your #Previews. No unit tests, no UI test suite, no special runner.

Diffing designed for easy review

See changes side-by-side or overlay to pinpoint what shifted. Approve intentional changes and keep regressions visible.

Control false positives

Set thresholds and masks in the Mac app or config file for dynamic regions to keep your signal clean as the app evolves.

Gallery view

Browse all previews with filtering and sorting to quickly assess UI changes as you develop your app.

How it works

A workflow built around Xcode builds and SwiftUI and UIKit previews.

01
Point PreviewLens at your code

Choose an Xcode project, app target, or Swift package.

02
Build as usual

On build, PreviewLens snapshots discovered #Previews. No separate test step.

03
Baseline once

Your first successful snapshot set becomes the baseline. Keep it local and review like any other artifact.

04
Diff on every build

Every build produces a new snapshot set and a visual diff against baseline.

05
Review and decide

Inspect diffs, apply thresholds and masks, then approve updates or keep failures flagged.

PreviewLens is optimized for everyday iteration, with fast feedback while you work instead of a heavy testing ceremony.

Core features (beta scope)

Everything you need for preview-based visual regression, local-first.

Automatic snapshots on build

  • Snapshots are generated automatically after you build.
  • Supports iOS, macOS, watchOS apps.
  • Supports SwiftUI and UIKit previews.

Baselining + diffs

  • Establish a baseline snapshot set.
  • Diff against baseline on every build.
  • Inspect diffs in a UI designed for debugging: side-by-side and overlay.

Thresholds / tolerance

  • Configure diff thresholds to ignore insignificant changes.
  • Reduce noise while still catching meaningful regressions.

Dynamic diff masks

  • Define masks visually in the Mac app.
  • Persist masks into a configuration file.
  • Keep masking logic transparent and reviewable.

Built for humans and AI

  • Configure everything in the Mac app UI or via a config file.
  • Install an agent skill to help configure diffs and review changes.
  • PreviewLens produces agent-readable results for automation workflows.

Supported targets

  • iOS apps
  • macOS apps
  • watchOS apps
  • Swift packages

If you can build your project, you can keep your previews honest.

For humans and their AI agents

Clear review UI for developers. Structured signals for agents.

Mac app for humans

Fast triage: filter to failing previews
Debug efficiently with side-by-side & overlay diffs overlay diffs
Adjust thresholds and masks without hand-editing files
Approve changes to keep baselines up to date

For AI workflows (config + agent-readable results)

Configuration can be driven by a file for agent edits
Structured signals enable automated follow-ups
Agent skill for configuring PreviewLens and reviewing results

Where PreviewLens goes next

Planned capabilities beyond the local-first beta.

Planned capabilities

    Interaction and navigation scenarios from previews
    Accessibility testing alongside visual diffs
    CI execution with PR reporting
    Cloud snapshot storage service

Mac app stays local-first

The Mac app is local-first. CI and storage become optional upgrades, not requirements.

Join the waitlist to shape the future of PreviewLens.

The founder

Mohamed Afifi

I'm Mohamed Afifi, an Apple developer based in Toronto, Canada 🇨🇦. I've been building software for over 15 years and have worked on products used by millions of people, including at Google and Amazon. I recently left Google to focus on building things I care about and to help others through my experience.

I'm building PreviewLens because I wanted faster, more reliable feedback on UI changes. I often need to update a component and see how it looks across multiple screens at once, or refactor UI without unintentionally changing its appearance. Snapshot tests are powerful but costly to maintain, and SwiftUI previews are limited when reviewing many screens together. PreviewLens is the tool I wished I had: fast, preview-native feedback built directly into my development workflow.

Amazon and Google are trademarks of their respective owners. PreviewLens is an independent project and not affiliated with or endorsed by these companies.

Join the beta waitlist.

PreviewLens is currently in beta and will be free during beta. Join the waitlist to get early access and help shape the product for real-world SwiftUI workflows.

No spam. Product updates and early access only.

Free during beta. Local-first Mac app.

Frequently asked questions

Quick answers to the most common questions.