
Cypress Mcp
io.github.miroslavmyrhaPublished by GitHub account miroslavmyrhav0.1.2Updated Oct 24, 2026
Shows an AI assistant the last cypress run: command log, errors, screenshots, DOM of failed tests.
The publisher's own server: Cypress Cloud MCP
Overview
Lets an AI assistant inspect the last Cypress test run: command log, errors, screenshots, and the DOM of failed tests.
- What you can do
- It reads the results of the last cypress run so the assistant can see which commands each test ran, the failure error, a screenshot, and the DOM snapshot at the moment of failure. Tools include list_specs, read_spec, get_config, get_last_run, get_screenshot, query_dom, and run_spec, which runs a single spec and waits for completion.
- When to use it
- Use it when Cypress tests run headless on your machine or in CI and the assistant should see why one failed. For debugging while writing tests in the open Cypress app, the official cypress tap fits better.
- Requirements
- Needs Node.js 18+ and Cypress 12+, plus registering the plugin in cypress.config and importing the support module. Installed as the npm package @miroslavmyrha/cypress-mcp and connected over stdio or HTTP; HTTP mode can set MCP_HTTP_TOKEN.
Installation
In SourceWeft
- Open Cypress Mcp in the dashboard and add it to a workspace.
- Enable the server for the chats that should use its tools.
Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.
Other MCP clients
Follow the launch instructions in the repository.
README
cypress-mcp
MCP server that shows an AI assistant what happened in your last cypress run: which commands each test ran, what failed, the error, a screenshot, and the page as it was at the moment of the failure.
It is made for headless runs, on your machine and in CI. That is the place the official tools do not reach, see How it compares.
Example
A spec with three tests, the last of which fails:
After cypress run, the assistant calls get_last_run and gets the commands that ran, the error and the path of a DOM snapshot (output shortened):
It can then look into the page as it was when the test failed. query_dom with the selector .todo-count:
So the counter exists, under another selector, and the assistant can fix the test without anyone pasting logs into the chat.
How it works
How it compares
Cypress has two tools of its own for AI assistants. They cover other situations than this one.
Use cypress tap while you write a test with the Cypress app open. Use this package when the tests run headless and the assistant should see why one failed.
The results are written in the after:spec event, which Cypress fires in run mode. In cypress open that event needs experimentalInteractiveRunEvents.
Before anything reaches the assistant, values that look like secrets are redacted, and content that comes from the tested application is marked as untrusted data.
Setup
1. Install
Note: the unscoped
cypress-mcpname on npm belongs to an unrelated project. Always use the scoped@miroslavmyrha/cypress-mcp.
2. Register the plugin in cypress.config.ts
3. Import support in cypress/support/e2e.ts
4a. Configure Claude Desktop / Claude Code (stdio transport)
In your MCP settings (~/.config/claude/claude_desktop_config.json or claude mcp add):
Or with claude mcp add:
4b. HTTP transport (Ollama, custom bridges)
MCP Tools
Output format of .cypress-mcp/last-run.json
All specs from a run are captured. In cypress run the accumulator resets on before:run. In cypress open results accumulate for the lifetime of the Cypress process. Failed tests include a domSnapshotPath pointing to an HTML file (up to 100 KB of document.body.outerHTML) stored under .cypress-mcp/snapshots/.
CLI options
Add .cypress-mcp to .gitignore
Environment variables
Development
This project uses Bun as the package manager:
Requirements
- Node.js 18+
- Cypress 12+ (developed and tested with Cypress 13)
Author
Miroslav Myrha
License
MIT
Source: README.md at commit f6b9153
Tools
0Version history
1- v0.1.2LatestOct 13, 2026
Score
50% of the applicable checks met
How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.
- Reached in the last 30 days25 pts
Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.
- Auth declared10 pts
Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.
- Tools listed15 pts
Answer tools/list without a credential, or ship a package that starts in a sandbox without one.
- DescriptionRequired15 pts
- Logo10 pts
- Documentation15 pts
- License10 pts
