
Browser
STDIOMCP server providing cloud-based browser automation with proxies and stealth capabilities
MCP server providing cloud-based browser automation with proxies and stealth capabilities
A Model Context Protocol (MCP) server that provides browser automation capabilities using Anchor Browser's remote browser service with Playwright. This server enables LLMs to interact with web pages through Anchor's cloud-based browsers with built-in proxies, stealth features, and advanced capabilities.
Since this is a custom Browser MCP server, you need to build it locally:
# Clone the repository git clone https://github.com/anchorbrowser/anchor-mcp.git cd anchor-mcp # Install dependencies and build npm install npm run build
sk-
)Add to your ~/.cursor/mcp.json
:
{ "mcpServers": { "anchor-browser": { "command": "node", "args": [ "/path/to/anchor-mcp/cli.js" ], "env": { "ANCHOR_API_KEY": "sk-your-api-key-here" } } } }
Add to your MCP configuration:
{ "mcpServers": { "anchor-browser": { "command": "node", "args": [ "/path/to/anchor-mcp/cli.js" ], "env": { "ANCHOR_API_KEY": "sk-your-api-key-here" } } } }
Add to your claude_desktop_config.json
:
{ "mcpServers": { "anchor-browser": { "command": "node", "args": [ "/path/to/anchor-mcp/cli.js" ], "env": { "ANCHOR_API_KEY": "sk-your-api-key-here" } } } }
After updating the configuration, restart your MCP client (Cursor, VS Code, etc.) to load the new server.
The Browser MCP server supports only essential configuration options:
node cli.js --help
--host <host>
- Host to bind server to (default: localhost, use 0.0.0.0 for all interfaces)--port <port>
- Port to listen on for HTTP transport (Docker/server mode){ "mcpServers": { "anchor-browser": { "command": "node", "args": [ "/path/to/anchor-mcp/cli.js", ], "env": { "ANCHOR_API_KEY": "sk-your-api-key-here" } } } }
For Docker or headless server environments:
# Run as HTTP server ANCHOR_API_KEY="sk-your-key" node cli.js --port 8931 --host 0.0.0.0
Then configure your MCP client to use the HTTP endpoint:
{ "mcpServers": { "anchor-browser": { "url": "http://localhost:8931/mcp" } } }
Since Anchor Browser handles all the complex browser management remotely, most traditional browser options are unnecessary:
This keeps the MCP server simple and focused on what matters: connecting to Anchor's remote browser service.
The Browser MCP server provides all standard browser automation tools:
anchor_navigate
- Navigate to URLsanchor_click
- Click elementsbrowser_type
- Type text into inputsbrowser_snapshot
- Get page accessibility treebrowser_take_screenshot
- Take screenshotsbrowser_evaluate
- Execute JavaScriptbrowser_wait_for
- Wait for conditionsbrowser_tab_new
- Open new tabsbrowser_tab_list
- List open tabsbrowser_tab_select
- Switch between tabsbrowser_tab_close
- Close tabsbrowser_file_upload
- Upload filesbrowser_handle_dialog
- Handle alerts/confirmsbrowser_network_requests
- View network trafficbrowser_pdf_save
- Generate PDFs (with --caps=pdf
)Error: Missing ANCHOR_API_KEY environment variable
Solution: Make sure your API key is correctly set in the MCP configuration.
npm run build
Solution: Make sure you have Node.js 18+ and run npm install
first.
Check the MCP logs for Anchor API responses and WebSocket connection status.
Each Anchor API key has session limits. Check your dashboard at anchorbrowser.io for usage.
To modify or extend the Browser MCP server:
# Make changes to TypeScript files in src/ # Then rebuild npm run build # Test your changes node cli.js --help
The server will automatically use Anchor's remote browsers for all operations, providing the benefits of cloud-based browser automation with advanced proxy and stealth capabilities.
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.