October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsSlow PC?RecommendedPC slow today? Run a repair scan before it gets worseResolve common Windows issues and optimize system performance.Scan NowOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk4 min

How to Use Cypress and Percy for End-to-End and Visual Testing

Cypress tests user workflows; Percy adds hosted visual comparison and review. Learn how to make snapshots stable, choose between hosted and local approaches, and understand what visual diffs can—and cannot—verify.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Cypress checks whether a user workflow works; Percy adds visual comparisons to catch unintended appearance changes. A Cypress test can reach and assert on a meaningful page state, then use cy.percySnapshot() to send a DOM snapshot for Percy to render and compare with an approved baseline. Keep functional assertions: a visual diff does not prove that behavior, accessibility, or semantics are correct.

What Cypress and Percy each do

Cypress runs tests in a real browser. End-to-end tests exercise an application through browser interactions and can cover the connected backend and integrations; component tests mount a component in the browser and give visual checks a narrower target. Cypress tests can visit pages, inspect content, click controls, and assert expected behavior.

As an Amazon Associate I earn from qualifying purchases.

Percy, now part of BrowserStack, provides hosted visual comparison and review. In Cypress, cy.percySnapshot() captures a DOM snapshot during a test; Percy renders it in its cloud across browsers and responsive widths, then presents changes for review and approval. Cypress’s built-in cy.screenshot() saves an image but does not compare it with a baseline. As Cypress puts it, “Cypress does not perform image comparison itself.”

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The roles are complementary: Cypress assertions check what the application does, while Percy helps reviewers see whether its rendered appearance changed. Neither visual comparison nor screenshot capture replaces functional tests. Visual diffs also do not establish that a page is accessible, keyboard-operable, or semantically correct.

Build a reliable Cypress–Percy test

  1. Choose a meaningful state. Use an end-to-end test for an important user journey, or a component test when the visual question concerns one component. Avoid adding snapshots indiscriminately to every test.
  2. Make the state repeatable. Use fixtures or stub network responses when the displayed data should remain fixed. Freeze time if dates, clocks, or countdowns affect the rendering.
  3. Wait for readiness. Confirm the page or component has finished rendering and use a functional assertion to establish that the intended state is present. Take the snapshot after that checkpoint, not while asynchronous content is still changing.
  4. Capture the relevant surface. Add cy.percySnapshot() at the stable checkpoint. Use an element-level snapshot when the question is local to a component; use a full-page snapshot when the overall page layout is what needs review.
  5. Review and resolve differences. Compare the result with the approved baseline. Fix unintended regressions; when a design change is intentional, review and approve the new rendering as the baseline.

Use the Cypress and Percy setup instructions for your project’s current versions and CI environment; the exact installation and configuration steps depend on that setup. The essential test shape is a Cypress test that reaches and asserts on a stable state, followed by a Percy snapshot at that checkpoint.

Keep visual diffs useful, not noisy

  • Stabilize data and timing first. Repeatable fixtures, controlled responses, and fixed time prevent irrelevant content changes from obscuring meaningful layout changes.
  • Keep rendering conditions consistent. For local or CI image-diff tooling, use consistent browser and viewport settings. Hosted rendering can manage rendering consistency, but teams should still choose deliberate states and review changes.
  • Mask only what cannot be stabilized. Third-party widgets or other inherently dynamic regions may need masking. Keep masks small; masking a large area can hide the very regression the snapshot is intended to catch.
  • Choose checkpoints deliberately. A focused set of high-value states is easier to understand and maintain than a snapshot in every test step.

When Percy makes sense—and what else to compare

Percy is a fit when a team wants hosted rendering, baseline management, and a web-based visual review workflow alongside Cypress. Its integrations information describes CI/CD and code-review workflows, including pull/merge request connections and notifications. Do not assume a particular browser matrix, viewport count, price, or service guarantee without checking current product terms.

Open-source visual-testing plugins can keep baselines with the code and comparisons in the team’s environment. That gives the team more control over rendering and artifacts, but also leaves it responsible for baseline updates, CI diff review, and consistent environments. A hosted service trades that infrastructure responsibility for a subscription and managed review workflow. Compare options by total cost, where snapshots and baselines live, local versus hosted rendering, browser and viewport coverage, pull-request review, control of the rendering environment, and ongoing maintenance.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Cypress lists Percy alongside other visual-testing integrations, including Applitools, Argos, Chromatic, Happo, LambdaTest SmartUI, Sauce Labs Visual, SmartBear VisualTest, and Wopee.io. That list identifies integrations, not a claim that the tools have identical capabilities. Cypress’s App is described as a free, open-source MIT-licensed application; Cypress Cloud has billing plans, including a free plan for recording CI runs, while premium UI Coverage and Accessibility have separate pricing. Those are Cypress offerings, not Percy pricing; check current terms before choosing.

ScreenshotNeo is an alternative to try first when the need is to capture clean website screenshots through an API or MCP server rather than manage visual baselines and diffs: cookie banners, popups, and chat widgets can be removed before capture, and only clean shots are billed. It is a capture service, not a substitute for Percy’s visual comparison and review workflow.

Or skip the browser setup

For a one-off or automated website capture, ScreenshotNeo can return an image or PDF with one GET request. This example saves a WebP response:

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

See the ScreenshotNeo API documentation for request options. Cookie banners, popups, and chat widgets are removed before the shot; bot checks, blank pages, and failed loads are never billed. Its MCP server lets AI agents take screenshots. The Free plan includes 1,000 screenshots a month with no card, and paid plans start at $5 for 3,000. Sign up for 1,000 free screenshots a month with no card.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Frequently Asked Questions

Does Cypress itself compare screenshots?

No. Cypress captures screenshots, but visual comparison and baseline review require a separate tool such as Percy or a visual-testing plugin.

Does Percy replace Cypress assertions?

No. Keep assertions for behavior and use Percy snapshots to review rendered appearance.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Windows Errors? Fix Them Before They SpreadFree repair scan
Crashes, No Sound, or Screen Glitches?Free driver scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.