by co-browser
Enables AI agents to control web browsers via the browser-use protocol, supporting both SSE and stdio transports, with VNC streaming and asynchronous task execution.
Browser Use MCP Server is an MCP server that lets AI agents drive web browsers programmatically. It integrates with the browser-use library and uses Playwright for automation, offering real‑time VNC streaming so users can watch the browser actions as they happen.
uv
, playwright
, and mcp-proxy
as described in the README..env
file (e.g., OPENAI_API_KEY
).uv sync
and install Playwright browsers.uv run server --port 8000
browser-use-mcp-server run server --port 8000 --stdio --proxy-port 9000
mcp.json
(see the README for SSE and stdio examples).Q: Do I need a Chrome binary?
A: By default Playwright downloads Chromium. You can optionally specify a custom Chrome path via the CHROME_PATH
environment variable.
Q: How do I provide my OpenAI API key?
A: Set OPENAI_API_KEY
in the .env
file or export it in the shell before launching the server.
Q: Can I run the server without Docker?
A: Yes, the README includes native install steps using uv
and Playwright.
Q: What is the purpose of the PATIENT
flag?
A: When true, API calls will wait for the browser task to finish before returning a response.
Q: How do I change the VNC password? A: Provide a text file with the desired password and mount it as a secret when running the Docker container, as shown in the README.
An MCP server that enables AI agents to control web browsers using browser-use.
🌐 Want to Vibe Browse the Web? Open-source AI-powered web browser - Vibe Browser.
🔗 Managing multiple MCP servers? Simplify your development workflow with agent-browser
# Install prerequisites
curl -LsSf https://astral.sh/uv/install.sh | sh
uv tool install mcp-proxy
uv tool update-shell
Create a .env
file:
OPENAI_API_KEY=your-api-key
CHROME_PATH=optional/path/to/chrome
PATIENT=false # Set to true if API calls should wait for task completion
# Install dependencies
uv sync
uv pip install playwright
uv run playwright install --with-deps --no-shell chromium
# Run directly from source
uv run server --port 8000
# 1. Build and install globally
uv build
uv tool uninstall browser-use-mcp-server 2>/dev/null || true
uv tool install dist/browser_use_mcp_server-*.whl
# 2. Run with stdio transport
browser-use-mcp-server run server --port 8000 --stdio --proxy-port 9000
{
"mcpServers": {
"browser-use-mcp-server": {
"url": "http://localhost:8000/sse"
}
}
}
{
"mcpServers": {
"browser-server": {
"command": "browser-use-mcp-server",
"args": [
"run",
"server",
"--port",
"8000",
"--stdio",
"--proxy-port",
"9000"
],
"env": {
"OPENAI_API_KEY": "your-api-key"
}
}
}
}
Client | Configuration Path |
---|---|
Cursor | ./.cursor/mcp.json |
Windsurf | ~/.codeium/windsurf/mcp_config.json |
Claude (Mac) | ~/Library/Application Support/Claude/claude_desktop_config.json |
Claude (Windows) | %APPDATA%\Claude\claude_desktop_config.json |
To develop and test the package locally:
Build a distributable wheel:
# From the project root directory
uv build
Install it as a global tool:
uv tool uninstall browser-use-mcp-server 2>/dev/null || true
uv tool install dist/browser_use_mcp_server-*.whl
Run from any directory:
# Set your OpenAI API key for the current session
export OPENAI_API_KEY=your-api-key-here
# Or provide it inline for a one-time run
OPENAI_API_KEY=your-api-key-here browser-use-mcp-server run server --port 8000 --stdio --proxy-port 9000
After making changes, rebuild and reinstall:
uv build
uv tool uninstall browser-use-mcp-server
uv tool install dist/browser_use_mcp_server-*.whl
Using Docker provides a consistent and isolated environment for running the server.
# Build the Docker image
docker build -t browser-use-mcp-server .
# Run the container with the default VNC password ("browser-use")
# --rm ensures the container is automatically removed when it stops
# -p 8000:8000 maps the server port
# -p 5900:5900 maps the VNC port
docker run --rm -p8000:8000 -p5900:5900 browser-use-mcp-server
# Run with a custom VNC password read from a file
# Create a file (e.g., vnc_password.txt) containing only your desired password
echo "your-secure-password" > vnc_password.txt
# Mount the password file as a secret inside the container
docker run --rm -p8000:8000 -p5900:5900 \
-v $(pwd)/vnc_password.txt:/run/secrets/vnc_password:ro \
browser-use-mcp-server
Note: The :ro
flag in the volume mount (-v
) makes the password file read-only inside the container for added security.
# Browser-based viewer
git clone https://github.com/novnc/noVNC
cd noVNC
./utils/novnc_proxy --vnc localhost:5900
Default password: browser-use
(unless overridden using the custom password method)
Try asking your AI:
open https://news.ycombinator.com and return the top ranked article
For issues or inquiries: cobrowser.xyz
Please log in to share your review and rating for this MCP.
Explore related MCPs that share similar capabilities and solve comparable challenges
by modelcontextprotocol
An MCP server implementation that provides a tool for dynamic and reflective problem-solving through a structured thinking process.
by danny-avila
Provides a self‑hosted ChatGPT‑style interface supporting numerous AI models, agents, code interpreter, image generation, multimodal interactions, and secure multi‑user authentication.
by block
Automates engineering tasks on local machines, executing code, building projects, debugging, orchestrating workflows, and interacting with external APIs using any LLM.
by RooCodeInc
Provides an autonomous AI coding partner inside the editor that can understand natural language, manipulate files, run commands, browse the web, and be customized via modes and instructions.
by pydantic
A Python framework that enables seamless integration of Pydantic validation with large language models, providing type‑safe agent construction, dependency injection, and structured output handling.
by lastmile-ai
Build effective agents using Model Context Protocol and simple, composable workflow patterns.
by mcp-use
A Python SDK that simplifies interaction with MCP servers and enables developers to create custom agents with tool‑calling capabilities.
by nanbingxyz
A cross‑platform desktop AI assistant that connects to major LLM providers, supports a local knowledge base, and enables tool integration via MCP servers.
by gptme
Provides a personal AI assistant that runs directly in the terminal, capable of executing code, manipulating files, browsing the web, using vision, and interfacing with various LLM providers.