Browser MCP
Provides tools to control and automate Google Chrome, such as navigating to URLs, clicking elements, taking screenshots, managing tabs, extracting page data, monitoring network requests, and injecting custom CSS.
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., "@Browser MCPgo to github.com and find the latest pull requests"
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.
About
Browser MCP is an MCP server + browser extension that allows you to automate your browser using AI applications like VS Code, Claude, Cursor, and Windsurf. Supports both Chrome and Firefox.
This is a fork of the original Browser MCP with the following changes:
Standalone build: All monorepo dependencies (
@repo/*,@r2r/messaging) replaced with local implementationsExtended toolset: 39 tools (up from 12 core tools) including tab management, JavaScript execution, cookie/storage access, CSS injection, network monitoring, and more
Cross-browser extension: Full-featured extension with all 36 command handlers, compatible with both Chrome (MV3) and Firefox (MV3)
WSL support: Auto-detects WSL IP and writes a config file for the extension to discover the correct WebSocket address
Connection resilience: Speed guidance in tool descriptions, connection error detection with retry hints
Related MCP server: agent-browser-mcp-server
Features
⚡ Fast: Automation happens locally on your machine, resulting in better performance without network latency.
🔒 Private: Since automation happens locally, your browser activity stays on your device and isn't sent to remote servers.
👤 Logged In: Uses your existing browser profile, keeping you logged into all your services.
🥷🏼 Stealth: Avoids basic bot detection and CAPTCHAs by using your real browser fingerprint.
Installation
Prerequisites
Node.js >= 18
Google Chrome, Chromium, or Firefox 113+
The Browser MCP extension (included in
extension/)
From source
git clone https://github.com/IlGabbia998/browsermcp-mcp.git
cd browsermcp-mcp
npm install
npm run buildLoad the extension
Chrome
Open Chrome and navigate to
chrome://extensionsEnable Developer mode
Click Load unpacked and select the
extension/folder from this projectThe extension will show in your toolbar — click it and hit Reconnect when the MCP server is running
Firefox
Firefox MV3 requires a different background entry than Chrome. You must switch the manifest before loading the extension.
Using the helper script (recommended):
npm run use:firefoxOr manually:
Copy
extension/manifest.firefox.jsontoextension/manifest.json(replacing the Chrome one)
Then load it:
Open Firefox and navigate to
about:debugging#/runtime/this-firefoxClick Load Temporary Add-on...
Select
extension/manifest.jsonfrom this projectThe extension will show in your toolbar — click it and hit Connect when the MCP server is running
Note: Chrome and Firefox use different manifest formats for MV3. Use
manifest.jsonfor Chrome (default) and runnpm run use:firefox(or copymanifest.firefox.json) for Firefox. Firefox temporary add-ons are removed when Firefox is restarted. To restore the Chrome manifest, runnpm run use:chrome.
Using in your MCP client
Add the server to your MCP client config. The built entry point is dist/index.js.
Claude Desktop
Edit ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
{
"mcpServers": {
"browser": {
"command": "node",
"args": ["/absolute/path/to/browsermcp-mcp/dist/index.js"]
}
}
}opencode
Add to your opencode.json:
{
"mcp": {
"browser": {
"type": "local",
"command": ["node", "/absolute/path/to/browsermcp-mcp/dist/index.js"],
"enabled": true
}
}
}Cursor / Windsurf
Add to your MCP settings (.cursor/mcp.json or equivalent):
{
"mcpServers": {
"browser": {
"command": "node",
"args": ["/absolute/path/to/browsermcp-mcp/dist/index.js"]
}
}
}Connect the browser
Start the MCP server (via your MCP client or
node dist/index.js)Open Chrome/Firefox and click the Browser MCP extension icon in the toolbar
Click Reconnect — the extension auto-discovers the server address
The MCP server will detect the connection automatically
Available Tools (39)
Core
Tool | Description |
| Navigate to a URL |
| Navigate back |
| Navigate forward |
| Capture an accessibility snapshot of the page |
| Click an element (by ref or description) |
| Hover over an element |
| Type text into an input field |
| Select an option in a dropdown |
| Drag from one element to another |
| Press a keyboard key |
| Wait for N seconds |
| Take a screenshot |
| Get browser console logs |
Navigation & Tabs
Tool | Description |
| Scroll the page (up/down/left/right) |
| Open a new tab |
| Reload the current page |
| List all open tabs |
| Close a tab by ID |
| Switch to a tab by ID |
Page Interaction
Tool | Description |
| Find text content on the page |
| Execute arbitrary JavaScript |
| Extract all links from the page |
| Query elements by CSS selector |
| Extract table data as structured JSON |
| Extract page metadata and OpenGraph tags |
| Extract all images from the page |
| Right-click an element |
| Double-click an element |
| Highlight elements matching a selector |
| Extract main article content |
| Wait for an element to appear |
| Get computed CSS styles for an element |
| Inject custom CSS into the page |
Storage & Cookies
Tool | Description |
| Get cookies for the current page |
| Set a cookie |
| Read from localStorage or sessionStorage |
| Write to localStorage or sessionStorage |
Monitoring
Tool | Description |
| Start/stop/query network request logging |
| Start/stop/query console log interception |
Usage examples
Ask your AI assistant to do things like:
"Go to github.com and take a screenshot"
"Click the login button and fill in my email"
"Scroll down and click the next page link"
"Extract all links from this page"
"Show me the cookies for this site"
"Run JavaScript to get the page title"
"Monitor network requests while I navigate"
"Inject a custom CSS theme on this page"
The AI uses accessibility snapshots to understand the page structure and interact with elements reliably.
Contributing
This is a standalone build of the Browser MCP server, extracted from the original monorepo. All monorepo dependencies have been replaced with local implementations.
Project structure
src/
index.ts # Entry point, tool registration
server.ts # MCP server with connection error handling
context.ts # WebSocket context management
ws.ts # WebSocket server creation
lib/
config/ # App and MCP configuration
messaging/ # WebSocket message sender
types/ # Zod schemas for all tools
tools/
snapshot.ts # Core interaction tools (click, type, hover, etc.)
common.ts # Navigation tools (navigate, goBack, etc.)
custom.ts # Screenshot, console logs
extended.ts # All extended tools (26 new tools)
tool.ts # Tool type definitions
utils/
port.ts # Port utilities
aria-snapshot.ts # Accessibility snapshot capture
extension/
background.js # Cross-browser service worker (36 command handlers)
manifest.json # Extension manifest (MV3, Chrome + Firefox compatible)
popup.html # Extension popup UI
popup.js # Popup JavaScript
icons/ # Extension iconsCredits
Browser MCP was adapted from the Playwright MCP server in order to automate the user's browser rather than creating new browser instances. This allows using the user's existing browser profile to use logged-in sessions and avoid bot detection mechanisms that commonly block automated browser use.
This server cannot be installed
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/IlGabbia998/browsermcp-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server