opencode-browser-control
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@opencode-browser-controlNavigate to https://www.wikipedia.org and take a snapshot"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
opencode-browser-control
Playwright-powered browser automation MCP server for OpenCode.
Controls Chrome/Edge with ARIA accessibility snapshots and numbered element refs — no CSS selectors, no guessing.
Quick Start
1. Install dependencies
npm install -g playwright-core
npx playwright install chromium2. Configure OpenCode
Add to ~/.config/opencode/opencode.json:
{
"mcp": {
"browser-control": {
"type": "local",
"command": ["npx", "-y", "opencode-browser-control"],
"enabled": true
}
}
}3. Restart OpenCode
The browser, browser_snapshot, browser_click, and browser_type tools will be available.
Related MCP server: Playwright MCP
Tools
browser(action, ...) — Multiplexed Tool
Action | Description | Key Params |
| Launch browser |
|
| Close browser | — |
| Open URL |
|
| ARIA snapshot with element refs |
|
| Click element by ref |
|
| Type into input by ref |
|
| Execute JavaScript |
|
| Full-page screenshot |
|
| List all tabs | — |
| Close a tab |
|
| Navigate history | — |
Shortcut Tools
Tool | Description |
| Get ARIA snapshot with |
| Click element by snapshot ref |
| Type into element by snapshot ref |
Typical Workflow
1. browser(action="navigate", url="https://example.com")
2. browser_snapshot() → returns e1: button "Login", e2: textbox "Email", ...
3. browser_type(ref="e2", text="user@example.com")
4. browser_click(ref="e1")
5. browser_snapshot() → verify resultBrowser Support
Auto-detects in priority order:
OS | Priority |
Windows | Edge → Chrome |
macOS | Chrome → Edge |
Linux | Chrome → Edge → Chromium |
Falls back to Playwright's bundled Chromium if no system browser is found.
Persistent Profile
A persistent profile is stored at ~/.opencode/browser-profile/{browser}/. Login state, cookies, and local storage persist across sessions. The profile is isolated from your normal browser — it won't interfere with your daily browsing.
Architecture
OpenCode ──MCP(stdio)──▶ index.mjs ──Playwright──▶ Edge/ChromeSingle-file Node.js MCP server. No HTTP middle layer, no browser extensions, no CDP port configuration. Playwright manages the browser lifecycle automatically.
Troubleshooting
Problem | Solution |
"playwright-core not found" |
|
Browser doesn't launch | Install Chromium: |
SPA navigation breaks refs | Re-run |
Elements not clickable | The snapshot only finds visible elements. Use |
License
MIT
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/FileXego/opencode-browser-control'
If you have feedback or need assistance with the MCP directory API, please join our Discord server