Skip to main content

FoxMCP fox logo

FoxMCP — Firefox Browser Automation via MCP

Connect an MCP-compatible AI assistant to Firefox. Manage tabs and windows, read pages, upload local files, organize bookmarks, search history, and inspect network requests.

FoxMCP has two parts: a Firefox extension and a local Python server. Your AI client talks to the server, which sends commands to the extension.

Privacy: Connected AI clients can access your browser data and run page scripts. Use trusted clients and consider a dedicated Firefox profile. See SECURITY.md for the threat model.

Quick start

PyPI packaging is prepared for the next release; foxmcp has not yet been published to PyPI. Use the GitHub installer below today. The upcoming uvx setup removes the server installation directory.

You need Firefox, an MCP client, Python 3.10+ with venv, and the commands bash, curl, unzip, and sha256sum. The commands below use a Bash shell. On Debian/Ubuntu, install missing prerequisites with sudo apt install python3 python3-venv curl unzip coreutils.

1. Install the server

Run this in a new directory where you want FoxMCP installed:

mkdir foxmcp && cd foxmcp
curl -fSL https://github.com/ThinkerYzu/foxmcp/releases/download/v1.5.0/install-from-github.sh | bash

The installer verifies the release archive checksums, creates venv/, installs Python dependencies, and creates start-foxmcp.sh. It also installs example scripts and a CLAUDE.md template, and offers to connect Claude Code.

For unattended setup, save the installer outside the target directory and run bash /path/to/install-from-github.sh --non-interactive from an empty directory.

2. Install the Firefox extension

Open FoxMCP on Firefox Add-ons and click Add to Firefox.

Use matching server and extension versions. Click the FoxMCP toolbar icon to see a mismatch warning with both versions inside the popup. No automatic dialog or notification opens. The server also logs a warning; older peers may show a version as unavailable. Tools remain available while you update both together. Mozilla review can delay the Add-ons version after a GitHub release; to try a version awaiting approval, use the temporary add-on instructions.

3. Start the server

From your installation directory:

./start-foxmcp.sh

Leave it running. Click the FoxMCP toolbar icon in Firefox and check that it shows a connected status. The default ports are 8765 for the extension's WebSocket connection and 3000 for the MCP HTTP endpoint.

4. Connect your AI client

For Claude Code, run this in another terminal:

claude mcp add --transport http foxmcp http://localhost:3000/mcp/

If the installer already connected Claude Code, skip that command.

For Codex, run:

codex mcp add foxmcp --url http://localhost:3000/mcp/

For another MCP client, add an HTTP server with URL http://localhost:3000/mcp/.

5. Try it

Ask your assistant:

List all open Firefox tabs.
Open https://example.org in a new tab.
Get the text from the current page.
Take a screenshot of the current tab.

To target a particular tab, right-click it in Firefox's tab bar and choose Tab ID = … (click to copy). Paste the copied tab_id = … into your request. Tab IDs change when Firefox restarts.

What you can do

Area Capabilities
Tabs and groups List, open, close, switch, reorder, move between windows, group and ungroup; take screenshots
Windows Create, close, focus, resize, position, minimize and maximize
Page content Read text or HTML, execute JavaScript, run predefined scripts, load local files for uploads
Navigation Go to a URL, go back or forward, reload
Bookmarks List, search, create, update, move and delete bookmarks and folders
History Search, list recent visits and delete entries
Network Monitor requests by URL pattern; inspect headers and captured text response bodies

Native tab groups require Firefox 139+. Local file uploads use files readable by the Python server; see loading local files. See the API reference for tool names and parameters.

Other setup options

Run with uvx (next release)

After the first PyPI release, install uv and the Firefox extension. For one Claude Code client, register a server it launches itself:

claude mcp add foxmcp -- uvx foxmcp --stdio

For several clients, start one shared HTTP server with uvx foxmcp, then use the HTTP registration commands. The extension connects to WebSocket port 8765 in either mode. Separate stdio clients still conflict on that port, and the first browser call may need a retry while the extension reconnects; see stdio tradeoffs.

The packaged command includes and enables the example scripts. An explicit FOXMCP_EXT_SCRIPTS overrides them; an empty value disables scripts. To match a particular extension release, use uvx --from foxmcp==VERSION foxmcp --stdio, replacing VERSION with that release's version. Python 3.10+ and Bash for the shell examples are required.

Install from source

You also need Git, make, and zip (on Debian/Ubuntu: sudo apt install git make zip).

git clone https://github.com/ThinkerYzu/foxmcp.git
cd foxmcp
make install
make package

Load the built extension in Firefox, then start the server with make run-server. Continue with Connect your AI client above.

Let your client start the server

Use stdio with --single-instance to start the server automatically and share it across chats. Configure each client to launch venv/bin/python server/server.py --stdio --single-instance, using absolute paths. Clients discover and share the browser connection on the extension port. They join an existing server or start a background worker automatically. Closing one chat leaves the others connected. Automatic workers stop after 60 seconds without clients; manually started servers keep running. On Windows, use venv\Scripts\python.exe. See stdio setup.

Configuration

Click the FoxMCP toolbar icon to change extension connection settings. If you change the WebSocket port, change it on both the extension and the server.

For manual startup, run these from the installation directory:

# Custom WebSocket and MCP HTTP ports
venv/bin/python server/server.py --port 9000 --mcp-port 4000

# Hide tool groups from clients
venv/bin/python server/server.py --disable-tools bookmarks,history

# Hide a group but keep its screenshot tool
venv/bin/python server/server.py --disable-tools tabs --enable-tools tabs_capture_screenshot

All 45 tools are enabled by default. Available groups are windows, tabs, containers, bookmarks, navigation, content, requests, history, and debug. See configuration for client examples and other options.

Firefox containers

Use containers_list to discover named containers and their opaque cookie_store_id values. Pass one to tabs_create to open in that container, or to tabs_list to filter. Use firefox-default for normal browsing. Omission keeps existing behavior; invalid selections fail without opening a fallback tab.

containers_create, containers_update and containers_remove manage persistent profile containers. Removal clears stored site data and refuses containers with open tabs. Containers survive client disconnects. See the API reference for details.

The extension requires contextualIdentities and cookies permissions for container APIs and tab selection. Installation can enable Firefox containers; subsequent disabling is respected. Update both extension and server together.

Predefined scripts

External executable scripts can generate JavaScript for FoxMCP to run in a tab. The release installer configures the examples in predefined-scripts/; the packaged foxmcp command uses its bundled examples by default. Both include DOM summaries, YouTube controls, calendar extraction, and a file-input helper. Ask your assistant which predefined scripts are available.

For your own scripts, set FOXMCP_EXT_SCRIPTS to their directory before starting the server. For example, save this as get-title.sh in that directory and run chmod +x get-title.sh:

#!/bin/bash
# Return the current page title.
echo 'document.title'

Then ask your assistant to run get-title.sh in a tab. Restart the server after adding scripts to refresh the list shown to clients. See the script guide for arguments, setup, and file upload examples.

Troubleshooting

Problem Check
Extension disconnected Start the server and check the host/port in the FoxMCP popup. curl -i http://localhost:8765 should return 426 Upgrade Required.
MCP client cannot connect Check its URL. curl -i http://localhost:3000/mcp/ should return a 307 redirect when using HTTP mode.
Server logs “address already in use” Another service owns a port. FoxMCP can keep running even when its MCP listener fails; use different ports and check both listeners.
Server reports missing Python packages Use venv/bin/python, or the provided startup script.
Built extension will not install Follow the Firefox channel and signing guidance.

For other errors, run the server in the foreground and inspect its output.

Documentation and development

To contribute, fork the repository, run make setup and make test, and submit a pull request with tests for new behavior.

Licensed under the MIT License.

Metadata

Release files for foxmcp 1.5.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for foxmcp 1.5.0
File Size Uploaded Provenance Actions
foxmcp-1.5.0.tar.gz 59.4 kB With provenance Details for foxmcp-1.5.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for foxmcp 1.5.0
File Interpreter ABI Platform Actions
foxmcp-1.5.0-py3-none-any.whl Python 3 none any Details for foxmcp-1.5.0-py3-none-any.whl

Total release size: 126.4 kB

Release files / foxmcp-1.5.0.tar.gz

Download URL foxmcp-1.5.0.tar.gz
Size 59.4 kB
Tags Source
SHA-256 checksum
How to use checksums
184fbce81b5be1d55761c94543f8715f16d6d79dc88472be7c6c676e4c04b4d7
BLAKE2b-256 checksum
How to use checksums
11905f812dcd26172b342eca71b809e7b802235b692e7d1daf0ef0784807c3fc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 25, 2026.

Transparency log

Release files / foxmcp-1.5.0-py3-none-any.whl

Download URL foxmcp-1.5.0-py3-none-any.whl
Size 67.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ee07115a0648edff34fe49773f5a430ed49b3a3c13c40b40aa0287daa9beb25d
BLAKE2b-256 checksum
How to use checksums
f40e5934b539a85fb701866113fdd2f805bfe7f322fd7636c3a66284354d3854
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 25, 2026.

Transparency log

Security for foxmcp 1.5.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for foxmcp-1.5.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 25, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.5.0 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page