# opencode-browser MCP server

> Enables AI-driven browser automation within the OpenCode editor to navigate websites, fill forms, and scrape data using Chrome or Edge.

- Repository: https://github.com/michaljach/opencode-browser
- Page: https://hostedmcp.org/servers/michaljach/opencode-browser
- Transport: stdio
- Stars: 117
- License: MIT

## Install

### Claude Code

```sh
claude mcp add opencode-browser -- npx -y opencode-browser
```

### Cursor (`~/.cursor/mcp.json`)

```json
{
  "mcpServers": {
    "opencode-browser": {
      "command": "npx",
      "args": [
        "-y",
        "opencode-browser"
      ]
    }
  }
}
```

### VS Code (`.vscode/mcp.json`)

```json
{
  "servers": {
    "opencode-browser": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "opencode-browser"
      ]
    }
  }
}
```

### VS Code CLI

```sh
code --add-mcp '{"name":"opencode-browser","type":"stdio","command":"npx","args":["-y","opencode-browser"]}'
```

### Claude Desktop (`claude_desktop_config.json`)

```json
{
  "mcpServers": {
    "opencode-browser": {
      "command": "npx",
      "args": [
        "-y",
        "opencode-browser"
      ]
    }
  }
}
```

### Codex

```sh
codex mcp add opencode-browser -- npx -y opencode-browser
```

### Codex config.toml (`~/.codex/config.toml`)

```toml
[mcp_servers.opencode-browser]
command = "npx"
args = ["-y", "opencode-browser"]
```

### Gemini CLI

```sh
gemini mcp add -s user opencode-browser npx -- -y opencode-browser
```

### Gemini settings.json (`~/.gemini/settings.json`)

```json
{
  "mcpServers": {
    "opencode-browser": {
      "command": "npx",
      "args": [
        "-y",
        "opencode-browser"
      ]
    }
  }
}
```

## Environment variables

| Name | Required | Secret | Description |
|---|---|---|---|
| `BROWSER_MCP_DEBUG` | no | no |  |

## FAQ

### What browsers are supported?

The plugin works with Google Chrome and Microsoft Edge.

### How do I install the plugin in OpenCode?

You can use the command 'npx opencode-browser init' to automatically create or update your configuration file.

### Does this work with OpenCode 2?

Yes, the plugin is a single package that supports both OpenCode 1 and OpenCode 2.
