Selenium MCP
Allows driving a real browser through Selenium Grid, providing tools for session management, navigation, clicking, typing, pressing keys, extracting element content, executing JavaScript, and taking screenshots.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
π Selenium Flow
One browser, many calls. Drive a real Chrome or Firefox on Selenium Grid from an agent over MCP, or from anything else over plain HTTP. Same actions, same server, one browser that stays exactly where you left it.
The whole idea, in one breath
Open a browser once. It stays alive (same page, same cookies, same scroll position) while an agent works a task one call at a time, or an n8n workflow steps from node to node. Nothing relaunches, nothing logs in twice.
agent ββββ MCP /mcp ββββββΆ βββββββββββββββββ βββββββββββββββββ
β selenium-flow β ββββββΆ β Selenium Grid β βββΆ π
workflow ββββ HTTP /browser βββΆ βββββββββββββββββ βββββββββββββββββ
holds no browser the browser
lives hereThe browser lives on the Grid, so the server can restart without anyone losing a tab. Keep its records in Redis and it remembers whose browser is whose across the restart too.
Related MCP server: Browser MCP
π§° Every action, both ways
Twenty actions, each an MCP tool and an HTTP endpoint with one schema between them. Hand a whole job to an agent, or drive the same steps yourself from an n8n HTTP node.
Action | |
Start a browser: Chrome or Firefox, any window size | |
Go to a URL | |
Click, double-click, right-click, hover, scroll to | |
Drag onto another element, or by an offset | |
Type into a field, or type a secret nobody sees | |
Press Tab, Enter, the arrows | |
Read text and HTML off the page | |
What is on the page, with a checked selector for each thing | |
Wait until JavaScript comes back true, or fail | |
A PNG of the viewport, the whole page or one element | |
Keep the page as a PDF or as HTML | |
Run JavaScript: the escape hatch | |
Step into an iframe and back out | |
Answer an alert, confirm or prompt | |
Change the window at any time | |
Put a file into a file input | |
Keep cookies and storage for the next browser | |
One captured response body | |
Wait for a person to hand the browser back | |
Give the Grid slot back, keep the workspace |
Most of them take an optional url: if the browser is somewhere else it goes there first, so you can jump straight to a page in one call. Every parameter and return field is on the wiki, generated from the live tool schemas.
π§ Workspaces outlive browsers
Name your workspace, with ?workspace=research-bot on the URL or an Sf-Workspace header, and you get the browser that belongs to that name. There is no session id anywhere. Call again with the same name after a reconnect, a restart or a week away, and you are back on the same browser at the same page.
When the Grid reaps an idle browser, or an admin ends one, the workspace keeps the page it was on and the settings it was opened with, so recovery is one call:
open_session() # back where you were, with the settings you choseBetween calls the server keeps your browser alive for 15 minutes, so an agent that stops to think doesn't come back to an empty page. workspace://current says where you are without opening anything.
π Watch it live, and take the wheel
The admin UI shows each workspace's browser live in its Live tab. When an agent hits a captcha or a sign-in it can't do, take control. While you hold it, the agent's calls that would change the page are refused and its reads still answer. Solve it and hand back: the agent, waiting in await_control, learns which pages you went through.
π Flows: do it once, run it forever
Drive a form once, save the steps under a name, and every run after that is one call:
run_flow(name="sign-up", params={"email": "a@example.com"})A step is a tool call, checked against the live schemas when it is saved. A flow runs in whatever browser you hold, so the same flow checks Chrome and then Firefox without an edit. Give it sites and paths, and a result on a matching page names it in flows_here, so an agent finds the flow for the page it is on. Every workspace has its own library beside a shared global one.
π Secrets: typed, never shown
Mount credentials the way Kubernetes mounts a Secret (a directory per secret, a file per key) and say which sites each may be typed on. An agent sees names and keys, never a value, and binds one where the value goes:
write(selector={"css": "#password"}, secret={"name": "nextcloud", "key": "password"})The server types it. If the value shows up later in a page, a result or a resource, it comes back as [secret:nextcloud/password]. A secret is refused on any site it wasn't allowed on.
πͺ Sign in once
save_site_data keeps the cookies, localStorage and sessionStorage of the sites a workspace visited. The next browser, even one reopened after a reap, has them restored before its first page loads, so the agent is still signed in.
π§Ύ See what the page saw
open_session(capture=true) keeps the browser's console and network traffic, masked, at workspace://console and workspace://network. A call that set off a page error says so in its result, and network_body fetches the response behind a failing request.
π Screenshots, prints, downloads and recordings
Give the server a data directory and every screenshot and print is kept with the workspace, outliving the browser. Downloads are listed while the browser lives, and keep_file saves one before it goes. Turn on recording and a browser opened with record=true has its whole life filmed by the Grid, filed into the workspace's Recordings. Every file comes with a time-limited signed link to hand to someone, or drop into an <img>.
π It teaches you how to use it
The server ships an Agent Skill at skill://selenium-flow/SKILL.md: seven rules, a whole task end to end, and a table of when to reach for each tool. Eight references, from reading pages to troubleshooting, are each their own resource, so an agent loads only the one its task needs.
A client that speaks the agents extension also finds the explorer, a subagent that explores a site in your workspace, runs the flows that fit each page, saves new ones and reports back.
π₯ The admin UI and MCP Apps
Open the server's root for every workspace: its browser, live screen, files, flows, saved site data, history and captured traffic. Sign in with the server's token or, for an admin role, through your OIDC provider.
Hosts that render MCP Apps get show(uri), which draws any resource the server serves inline: your workspace, its files, flows, secrets and the skill. A client that can't read resources gets list_resources and read_resource instead.
π Quick start
git clone https://github.com/kubed-io/selenium-flow.git && cd selenium-flow
docker compose up --buildThat starts the server on port 8000 with a Chromium Grid beside it, and auth off. Open a browser over HTTP:
curl -X POST localhost:8000/browser \
-H 'Sf-Workspace: demo' -H 'Content-Type: application/json' \
-d '{"url": "https://example.com", "width": 1280, "height": 800}'Point an MCP client at http://localhost:8000/mcp?workspace=demo, and open http://localhost:8000 to watch the demo workspace in its Live tab. π
In production, set AUTH_TOKEN and send it as Authorization: Bearer <token>. Every setting is a config file key, an environment variable and a flag: see Configuration.
π Where next
The wiki: Installing in Claude, VS Code, n8n and others, Deployment, Configuration, and a page per action.
The spec: every requirement, one area per file.
CONTRIBUTING.md: setting up the repo, the tests, CI and releases.
Docker Hub:
kubed/selenium-flow.
π Licence
MIT. See LICENSE.
Not affiliated with, endorsed by, or sponsored by the Selenium project. "Selenium" is a trademark of the Software Freedom Conservancy, used here only to identify the software this server drives.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogβ¦
This server cannot be deployed
Maintenance
Related MCP Connectors
Hosted real Google Chrome MCP with per-user persistent state. Navigate, click, type, screenshot.
Stealth web browser for agents: search, fetch, click, download and type in persistent MCP sessions.
Launch, inspect, control, and share isolated cloud browsers for your agents.
Undetectable cloud browser sessions for AI agents and scrapers. Navigate, extract, click, captcha.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables MCP clients to drive a real, logged-in Chrome browser for web automation tasks like navigation, clicking, typing, and screenshotting.MIT
- FlicenseNot gradedqualityBmaintenanceEnables MCP clients to control a real local browser window for web automation tasks such as clicking, typing, scrolling, and taking screenshots.184 npm-
- AlicenseAqualityCmaintenanceEnables AI agents and MCP clients to automate web browsers via Selenium WebDriver, supporting Chrome, Firefox, and Edge in headless or visible mode with tools for navigation, interaction, content extraction, screenshots, and scripting.21MIT
- AlicenseNot gradedqualityAmaintenanceEnables remote agents to control a local Chrome/Edge browser via MCP, supporting navigation, snapshots, clicks, typing, screenshots, and script execution.25 npmISC