Firefox Devtools MCP logo

Firefox Devtools MCP

by freema

Automates Firefox through WebDriver BiDi for tab control, DOM interaction, screenshots, downloads, and browser diagnostics.

Install Firefox Devtools MCP

Pick your client, then add it in one click or paste the config.

STDIONode.js
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "freema-firefox-devtools-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@mozilla/firefox-devtools-mcp@latest"
      ]
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

Install not yet sandbox-tested— the server itself is confirmed live (we called its tools/list endpoint). The stdio install command is a separate, ongoing check.

Overview

freema/firefox-devtools-mcp connects MCP clients to a local Firefox instance through WebDriver BiDi and Selenium WebDriver. It supports tab navigation, snapshot-based DOM interaction, form entry, file uploads, screenshots, downloads, dialogs, and Firefox session diagnostics. Reach for it when an agent needs to browse websites, complete multi-step flows, test browser behavior, or inspect a page during development. Firefox can be launched locally or an existing session can be attached, with optional headless operation and selectable tool modules.

Use cases

  • Automate multi-step website workflows
  • Test forms, navigation, dialogs, and downloads
  • Inspect pages during web development
  • Capture page or element screenshots
  • Read and interact with Firefox tabs

Key features

  • WebDriver BiDi Firefox control
  • Snapshot and UID-based DOM interaction
  • Tab, form, dialog, and download management
  • Viewport and screenshot capture
  • Firefox output and session diagnostics
  • Configurable tool presets and browser startup

Tools34

What Firefox Devtools MCP lets your agent do. Expand a tool for its parameters.

Verified live~3.7k tokens of context

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked 1d ago

Recent health check succeeded.

20/20 checks healthy over the last 78d

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 8d ago via OSV.dev · @mozilla/firefox-devtools-mcp@latest (npm)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

npm downloads15kPackage downloads in the last 30 days.
Last commit2d agoMost recent push to the default branch.
Tools exposed34Callable tools this server registers over MCP.
Directory activity8 viewsConfig copies, upvotes, and views on AllMCPs.

How Firefox Devtools MCP works

What freema/firefox-devtools-mcp does

freema/firefox-devtools-mcp gives an MCP client control of Firefox for browser automation and development workflows. It can open, select, navigate, and close tabs; read visible page text; capture DOM snapshots; and interact with elements identified by stable snapshot UIDs. The server also supports screenshots, downloads, browser dialogs, viewport changes, history navigation, Firefox output inspection, and extension installation.

The browser interaction model is useful for agents that need to read pages, fill forms, follow multi-step website flows, or exercise a web application. Snapshot UIDs let a client refer to elements without relying on generated CSS selectors for every action. The server also supports network monitoring, console capture, and screenshots for browser-oriented testing and inspection.

How it works

The server communicates with Firefox through WebDriver BiDi, using Selenium WebDriver underneath. By default it starts a Firefox session, but it can instead connect to an already-running browser. A start URL, Firefox binary, profile, viewport, headless mode, browser arguments, preferences, and connection settings can be supplied through command-line options or their corresponding environment variables.

A typical interaction lists available tabs, selects one, and navigates or reads its contents. For structured interaction, the client captures a snapshot, uses the returned UID values with actions such as clicking, hovering, filling, dragging, or uploading, and captures another snapshot after navigation or major DOM changes. UIDs become invalid when their element is removed or the page navigates.

Setup and configuration

The runtime requires Node.js 20.19.0 or newer and Firefox 100 or newer. The published package can be started locally with npx @mozilla/firefox-devtools-mcp@latest. It can also be run from Docker using the repository's Dockerfile. MCP Inspector can be used to connect to the server for interactive testing.

Useful settings include --headless, --viewport 1280x720, --start-url, --firefox-path, --profile-path, and --connect-existing. The --marionette-port option selects the port for an existing-browser connection. Tool exposure can be narrowed with --tool-preset slim, basic, developer, mozilla, or all, or controlled explicitly with --tools.

Tools and capabilities

  • Manage tabs with list_pages, new_page, navigate_page, select_page, and close_page.
  • Inspect content using get_page_text, take_snapshot, resolve_uid_to_selector, and clear_snapshot.
  • Interact with snapshot elements through clicking, hovering, text entry, form filling, dragging, file uploads, and key presses.
  • Capture viewport or element screenshots, including full-page screenshots.
  • Track and manage downloads, including allow, deny, and reset behavior.
  • Accept or dismiss browser dialogs and move through back/forward history.
  • Adjust viewport dimensions and inspect Firefox output and instance information.
  • Install Firefox extensions from archives, encoded data, or unpacked directories.
  • End a session while leaving an externally connected Firefox process running when applicable.

Limitations and notes

Firefox must be installed locally for the normal setup, so hosted environments without a local browser are not suitable. Use a dedicated Firefox profile rather than a regular personal profile because the agent may reach sites, cookies, and saved sessions available to that browser. Pages can contain prompt-injection content, so restrict browsing to trusted or controlled sites.

Snapshot UIDs are not permanent across navigation or element removal. The download-handling option that bypasses the native save dialog requires a recent Firefox version. Firefox accepts one client at a time in connect-existing mode; another client must wait until the session is released or its idle timeout expires.

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Firefox Devtools MCP

freema/firefox-devtools-mcp is an MCP server that connects AI clients to Firefox through WebDriver BiDi. Its main tools manage tabs, navigate pages, read text, capture DOM snapshots, click and fill elements by UID, take screenshots, handle downloads and dialogs, and inspect Firefox session output.

Install it by running `npx @mozilla/firefox-devtools-mcp@latest` from an MCP client configuration. The runtime needs Node.js 20.19.0 or newer and Firefox 100 or newer. It can also be run with Docker using the repository's Dockerfile.

Yes, freema/firefox-devtools-mcp works with Cursor. It also supports Claude Code, Claude Desktop, Cline, Codex, and other MCP clients. Configure the client to launch the package with `npx`, then provide optional browser arguments or environment variables.

Capture a DOM snapshot with `take_snapshot`, then pass the returned stable UID to tools such as `click_by_uid`, `fill_by_uid`, `hover_by_uid`, or `upload_file_by_uid`. UIDs stop working when the element is removed or the page navigates, so capture a new snapshot when needed.

Yes, run it with the `--headless` option or set `FIREFOX_HEADLESS=true`. You can also set an initial window size with `--viewport`, choose a start page with `--start-url`, and attach to an existing Firefox session with `--connect-existing`.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewFirefox Devtools MCP AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/freema-firefox-devtools-mcp?style=directory)](https://allmcps.com/mcp/freema-firefox-devtools-mcp)
HTML Embed
<a href="https://allmcps.com/mcp/freema-firefox-devtools-mcp"><img src="https://allmcps.com/api/badge/freema-firefox-devtools-mcp?style=directory" alt="Firefox Devtools MCP on AllMCPs" /></a>