Get the FREE Ultimate OpenClaw Setup Guide →

rust-browser

Browser automation for Claude via WebDriver and MCP. Support for Chrome/Firefox with stdio/HTTP transport.

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio emillindfors-rust-browser-mcp rust-browser-mcp --transport stdio --browser chrome \
  --env WEBDRIVER_HEADLESS="true"

How to use

The rust-browser MCP server provides a WebDriver-compatible Model Context Protocol interface for controlling browser automation across Chrome and other supported browsers. It offers multi-session support, performance monitoring, and advanced automation capabilities that Claude and Claude Code can leverage through MCP. Typical usage involves starting the MCP server in a chosen transport mode (stdio for local usage or http for remote access), then configuring Claude Desktop or Claude Code to connect to the MCP endpoint. Once connected, you can issue high-level browser actions such as navigate, click, fill forms, take screenshots, and run performance checks, all through the available tool APIs exposed by the MCP server.

Key capabilities include:

  • Session management: run and manage multiple browser sessions concurrently, with the option to isolate sessions by ID and browser type.
  • Navigation & interaction: navigate to URLs, click elements, input text, capture screenshots, and extract page data.
  • Advanced automation: form filling, login automation, dynamic waits, and JavaScript execution for complex interactions.
  • Performance & monitoring: access performance metrics, memory usage, and timing data to diagnose speed and resource usage.
  • Health & diagnostics: check driver health, restart failed drivers, and route requests to healthy sessions.

To use the HTTP transport, start the server with the http transport flags and point Claude at the HTTP endpoint. For local development or debugging, stdio transport is recommended. Claude can then issue MCP commands to the server via the configured endpoint and utilize the available tools for automation, testing, and monitoring.

How to install

Prerequisites:

  • A supported operating system (Linux, macOS, or Windows) with shell access.
  • A Rust toolchain (Rust stable with Cargo) if building from source.
  • Optional: Prebuilt binaries for quick setup (as provided in the project releases).

Option A — Install from prebuilt binary:

  1. Download the appropriate binary for your platform from the project releases.
  2. Extract the archive to a desired location.
  3. Ensure the binary is executable:
    • Linux/macOS: chmod +x rust-browser-mcp
  4. Run the MCP server in your preferred transport mode (stdio for local use, http for remote access).

Option B — Build from source:

  1. Install Rust toolchain from https://www.rust-lang.org/tools/install
  2. Clone the repository: git clone https://github.com/EmilLindfors/rust-browser-mcp.git
  3. Build the release binary: cd rust-browser-mcp cargo build --release
  4. The binary will be at: target/release/rust-browser-mcp

Browser prerequisites:

  • Chrome: chromedriver installed (as shown in the README prerequisites).
  • Firefox: geckodriver installed.

Example run commands after installation:

  • stdio transport (local): rust-browser-mcp --transport stdio --browser chrome
  • HTTP transport (remote): rust-browser-mcp --transport http --bind 0.0.0.0:8080 --browser chrome --no-auth

Configure MCP clients (Claude) to point at the server endpoint you started.

Additional notes

Tips and considerations:

  • For production deployments, consider enabling HTTP transport with authentication and proper TLS termination.
  • Use multi-session features to isolate testing environments or simulate concurrent user activity.
  • Ensure that the host has the required browser drivers (chromedriver/geckodriver) installed and accessible in PATH if you’re using a local setup.
  • When using performance monitoring, you can enable WEBDRIVER_ENABLE_PERFORMANCE_MEMORY and other related flags to collect richer metrics.
  • If you encounter startup timeouts, adjust WEBDRIVER_STARTUP_TIMEOUT_MS to give drivers more time to initialize in your environment.
  • If you need to support multiple browsers, you can run multiple sessions with different browser arguments using concurrent session features.
  • In HTTP mode, consider enabling rate limiting and proper OAuth configuration to protect the endpoint in production.

Related MCP Servers

Sponsor this space

Reach thousands of developers