Selenium MCP server for AI agents β 38 browser automation tools with snapshots and sessions.
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β or use 1-click editor setup below.
π‘ Paste the JSON block into your client's configuration file under mcpServers, then restart the application.
Selenium MCP server for AI agents β 39 tools for real-browser automation: navigation, clicking, typing, assertions, screenshots, multi-session management, page snapshots with stable element refs, persistent selector hints, and batched multi-step execution.
Built with TypeScript, the official MCP SDK, and Selenium WebDriver β strict zod input validation, explicit waits, and structured responses designed for LLM agents.
Add to your client's MCP config (e.g. claude_desktop_config.json or .cursor/mcp.json):
Settings β Tools β AI Assistant β Model Context Protocol β Add, with command npx and arguments -y @gaforov/selenium-mcp@latest. Full walkthrough in docs/CLIENT_INTEGRATION.md.
Then point your MCP client at node /absolute/path/to/selenium-mcp/dist/server.js.
Ask your AI agent:
Use selenium-mcp to open Chrome, go to https://example.com, read the page title, take a screenshot, and close the browser.
The agent chains start_browser β navigate β get_title β take_screenshot β stop_browser on its own β no scripting needed.
Most Selenium MCP servers wrap WebDriver's basic commands. This one adds the layer that makes agents reliable:
| Capability | selenium-mcp | Typical Selenium MCP servers |
|---|---|---|
Page snapshot with stable element refs (capture_page) | β | rare |
Persistent per-domain selector memory (selector_hint_*) | β | β |
| Parallel multi-session browsing | β | rare |
| Batched multi-step execution in one call | β | β |
| Built-in test assertions | β | some |
| Tool-call tracing (NDJSON audit log) | β | β |
| Strict input validation + structured errors | β | varies |
capture_page returns a page snapshot with stable element refs the agent can act on directly, no brittle selector guessingbatch_execute runs constrained multi-step sequences in a single tool call, cutting round-trips| Category | Tools |
|---|---|
| Browser lifecycle | start_browser, stop_browser, session_create, session_select, session_list, session_destroy |
| Navigation | open_url, navigate, get_current_url, get_title |
| Element discovery | find_element, wait_for_element, wait_until_visible, capture_page, get_page_source |
| Interaction | click, retry_click, interact (hover/double/right-click), type, press_key, upload_file |
| Reading | get_text, get_attribute |
| Assertions | assert_text, assert_visible, assert_attribute |
| Scripting | execute_script, batch_execute |
| Selector hints | selector_hint_save, selector_hint_get, selector_hint_list, selector_hint_delete |
| Windows & context | window, frame, alert |
| Cookies | add_cookie, get_cookies, delete_cookie |
| Capture | take_screenshot |
Full parameter documentation: docs/TOOL_REFERENCE.md
browser-status://current β live browser/session statusaccessibility://current β accessibility snapshot of the current pageEnable lightweight NDJSON tracing of all tool calls:
If SELENIUM_MCP_TRACE_PATH is omitted, the default is logs/selenium-mcp-trace.ndjson.
Contributions are welcome β bug reports, feature requests, and pull requests. See CONTRIBUTING.md to get started.
MIT. See LICENSE.
No reviews yet β be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/selenium-mcp)<a href="https://allmcps.com/mcp/selenium-mcp"><img src="https://allmcps.com/api/badge/selenium-mcp?style=directory" alt="Selenium MCP on AllMCPs" /></a>