Skip to main content

Firefox Browser MCP — Server

An MCP server that lets an LLM client drive a real Firefox browser — every tab, its DOM, arbitrary CSS selectors, and its network/API traffic. It talks to the companion firefox-extension/ WebExtension over a local WebSocket bridge.

MCP client (Claude Desktop, etc.)
        │  stdio (MCP)
        ▼
firefox-browser-mcp  ──ws://127.0.0.1:9010──►  Firefox extension  ──►  All tabs

Run with uvx

uvx --from ./mcp-server firefox-browser-mcp

Once published to PyPI: uvx firefox-browser-mcp.

Configure your MCP client

{
  "mcpServers": {
    "firefox-browser": {
      "command": "uvx",
      "args": ["--from", "/absolute/path/to/mcp-server", "firefox-browser-mcp"]
    }
  }
}

Targeting tabs

Every tab has a stable numeric id (plus title and url). Get them with browser_list_tabs. Most tools accept an optional tab argument:

tab value Meaning
omitted the currently active tab
123 / "123" the tab whose id is 123
"github.com" first tab whose url contains it
"Inbox" first tab whose title contains it

Environment variables

Variable Default Description
FBMCP_HOST 127.0.0.1 WebSocket bridge host
FBMCP_PORT 9010 WebSocket bridge port
FBMCP_LOG_LEVEL INFO Python logging level

If you change the port, update the bridge URL in the extension popup.

Tools

Tabsbrowser_list_tabs (id/title/url of every tab, all windows), browser_select_tab, browser_new_tab, browser_close_tab.

Navigationbrowser_navigate, browser_go_back, browser_go_forward, browser_reload.

Inspection & extractionbrowser_snapshot (accessibility tree with ref ids), browser_query (any CSS selector → refs, text, attributes, html), browser_get_text, browser_get_html, browser_get_attribute, browser_eval (run JS and return the result), browser_get_url, browser_screenshot, browser_get_console_logs.

Network / APIbrowser_get_network (captured requests with method, url, status, content-type, request & response bodies), browser_clear_network.

Interactionbrowser_click, browser_type, browser_hover, browser_select_option, browser_press_key, browser_scroll, browser_wait. Interaction tools accept either a ref (from snapshot/query) or a CSS selector.

Statusbrowser_status.

Examples (what an agent can do)

  • "List my tabs, then read the article in the tab with 'wikipedia' in its url": browser_list_tabsbrowser_get_text(tab="wikipedia").
  • "Grab all product prices": browser_query(selector=".price") or browser_eval(script="return Array.from(document.querySelectorAll('.price')).map(e=>e.textContent)").
  • "Show the API calls this page made": browser_get_network(filter="xmlhttprequest") (includes JSON response bodies).
  • "Log into the form": browser_type(selector="#email", text=...), browser_type(selector="#password", text=..., submit=True).

Development

cd mcp-server
uv venv && source .venv/bin/activate
uv pip install -e .
python -m firefox_browser_mcp.server

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

firefox_browser_mcp-0.1.0.tar.gz (7.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

firefox_browser_mcp-0.1.0-py3-none-any.whl (9.0 kB view details)

Uploaded Python 3

File details

Details for the file firefox_browser_mcp-0.1.0.tar.gz.

File metadata

  • Download URL: firefox_browser_mcp-0.1.0.tar.gz
  • Upload date:
  • Size: 7.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.14

File hashes

Hashes for firefox_browser_mcp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 64c825c9020043938f3a3fbf9fe66488faf8adf9d43c4c1ddf0a5de0cb3b6875
MD5 e2a046d90f5a0fbdcba5df8ed5c2c962
BLAKE2b-256 aae49d63435ac8288bb997e2e2b313b9a62552e52447d2fc3aad89caf7c19dfb

See more details on using hashes here.

File details

Details for the file firefox_browser_mcp-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for firefox_browser_mcp-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cc050cd56a0f5af97f52ac44ce3c401609da99a7cbaa5726a6f78420930a73c5
MD5 422de0da8a3e190b1176b4b7eb1c06ea
BLAKE2b-256 1bbed8f4c47f452f8467d1cd5c8b41ae6cee5651e909f87f0db41b7bbccdc48c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page