gecko-mcp
v2.2.4Control Firefox browsers (Floorp, LibreWolf, Zen, Firefox) from any MCP client.
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
list_tabs
List all open tabs in Floorp (title, URL, browserId, and whether each is active or pinned). Use the browserId to target other tools.
open_tab
Open a URL in a new Floorp tab.
| Parameter | Type | Description |
|---|---|---|
url * | string | The URL to open (must include http:// or https://). |
background | boolean | Open in the background without focusing the new tab. Default: false. |
get_active_tab
Return the active tab's title, URL and browserId. Note: with multiple browser windows open, 'active' is ambiguous — prefer the browserId returned by open_tab, or pick from list_tabs.
close_tab
Close a tab by its browserId (from list_tabs).
| Parameter | Type | Description |
|---|---|---|
browserId * | string | browserId of the tab to close (from list_tabs). |
read_page
Read a tab's content. Returns clean Markdown by default; can also return raw HTML or the accessibility tree. Output is capped (default 25 KB) to protect the context — to LOCATE a specific element use `find` (cheaper) instead. Targets the active tab unless a browserId is given.
| Parameter | Type | Description |
|---|---|---|
browserId | string | browserId of the tab to read (from list_tabs). Defaults to the active tab. |
format | string | Output format. Default: markdown. |
maxChars | integer | Truncate output to this many characters. Default 25000. Pass 0 for no cap. |
screenshot
Take a screenshot of a tab and return it as a PNG image. Targets the active tab unless a browserId is given.
| Parameter | Type | Description |
|---|---|---|
browserId | string | browserId of the tab to capture (from list_tabs). Defaults to the active tab. |
fullPage | boolean | Capture the full scrollable page instead of just the viewport. Default: false. |
find
Locate elements on a tab by visible text and/or tag and get a ready-to-use CSS `selector` for each — one fast call that searches the page server-side and returns ~1 KB instead of the whole HTML. Use this INSTEAD of read_page to find a button, link, or field, then pass the returned selector straight to click/type/etc. Provide `text`, `tag`, or both. Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
browserId | string | Target tab (from list_tabs). Defaults to active. |
limit | integer | Max matches to return. Default 25. |
tag | string | Restrict to a tag, e.g. "button", "a", "input", "select". |
text | string | Visible text to match (substring, case-insensitive). |
click
Click an element by CSS selector OR by a `ref` (fingerprint) from `snapshot`. Auto-scrolls the element into view first (fixes off-screen 'not actionable'). Targets the active tab unless a browserId is given.
| Parameter | Type | Description |
|---|---|---|
browserId | string | Target tab (from list_tabs). Defaults to active. |
button | string | Mouse button. Default: left. |
ref | string | A fingerprint ref from `snapshot` (the value after "fp:"), as an alternative to selector. |
selector | string | CSS selector, e.g. "button[type=submit]" or "a.login". |
snapshot
Capture a structured snapshot of a tab: clean Markdown with inline fingerprint refs (`<!--fp:...-->`) and an 'Element Selector Map' (fp | tag | text). Use this instead of read_page+grep to locate elements, then pass a `ref` to `click`. Targets the active tab unless a browserId is given.
| Parameter | Type | Description |
|---|---|---|
browserId | string | Target tab (from list_tabs). Defaults to active. |
type_text
Type text into an input or textarea by CSS selector (clears it first by default). Targets the active tab unless a browserId is given.
| Parameter | Type | Description |
|---|---|---|
selector * | string | CSS selector of the input/textarea. |
text * | string | The text to type. |
browserId | string | Target tab (from list_tabs). Defaults to active. |
clear | boolean | Clear the field before typing. Default: true. |
fill_form
Fill multiple form fields at once. `fields` maps CSS selectors (or field names) to values. Targets the active tab unless a browserId is given.
| Parameter | Type | Description |
|---|---|---|
fields * | object | Map of selector/name to value, e.g. { "#email": "a@b.com", "#password": "secret" }. |
browserId | string | Target tab (from list_tabs). Defaults to active. |
press_key
Press a keyboard key in the page (e.g. "Enter", "Tab", "Escape", "ArrowDown"). Targets the active tab unless a browserId is given.
| Parameter | Type | Description |
|---|---|---|
key * | string | Key name, e.g. "Enter". |
browserId | string | Target tab (from list_tabs). Defaults to active. |
wait_for_element
Wait for an element to reach a state (attached / visible / hidden / detached). Useful after navigation or actions that load content.
| Parameter | Type | Description |
|---|---|---|
selector * | string | CSS selector to wait for. |
browserId | string | Target tab (from list_tabs). Defaults to active. |
state | string | State to wait for. Default: visible. |
timeoutMs | integer | Timeout in milliseconds. Default: 5000. |
get_value
Read the current value of an input, textarea, or select by CSS selector. SENSITIVE: this CAN read the value of password fields and other secrets the user has typed — only use it on fields the user asked about, never to harvest credentials a page is requesting. Targets the active tab unless a browserId is given.
| Parameter | Type | Description |
|---|---|---|
selector * | string | CSS selector of the field to read. |
browserId | string | Target tab (from list_tabs). Defaults to active. |
real_type
Type text into Floorp's currently focused element using REAL OS keyboard events (isTrusted). Use for React/rich editors where `type_text` silently fails. Focus the field first with `click`. Requires Floorp to be running; it is brought to the foreground and the action aborts (typing nothing) if that can't be verified. Windows only.
| Parameter | Type | Description |
|---|---|---|
text * | string | The text to type via the real keyboard. |
real_key
Press a key or combo via REAL OS keyboard events, e.g. "Enter", "Tab", "Escape", "ctrl+a", "ctrl+shift+k". Use "Enter" to submit React composers that ignore synthetic clicks. Focus the field first. Windows only.
| Parameter | Type | Description |
|---|---|---|
key * | string | Key or combo, e.g. "Enter" or "ctrl+a". |
real_clear
Select-all + delete via REAL OS keyboard events — reliably clears a focused rich/contenteditable editor (where synthetic Ctrl+A does not work). Focus the field first with `click`. Windows only.
hover
Hover the mouse over an element (CSS selector or `ref`). Auto-scrolls into view. Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
browserId | string | Target tab. Defaults to active. |
ref | string | Fingerprint ref from snapshot. |
selector | string | CSS selector. |
double_click
Double-click an element (CSS selector or `ref`). Auto-scrolls into view. Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
browserId | string | Target tab. Defaults to active. |
ref | string | Fingerprint ref from snapshot. |
selector | string | CSS selector. |
right_click
Right-click (context menu) an element (CSS selector or `ref`). Auto-scrolls into view. Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
browserId | string | Target tab. Defaults to active. |
ref | string | Fingerprint ref from snapshot. |
selector | string | CSS selector. |
select_option
Choose an option in a <select> dropdown by its value. Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
selector * | string | CSS selector of the <select>. |
value * | string | The option value (or visible text) to select. |
browserId | string | Target tab. Defaults to active. |
set_checked
Check or uncheck a checkbox/radio. Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
checked * | boolean | true to check, false to uncheck. |
selector * | string | CSS selector of the checkbox/radio. |
browserId | string | Target tab. Defaults to active. |
submit_form
Submit a form (give a selector of the form or a field inside it; omit to submit the focused form). Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
browserId | string | Target tab. Defaults to active. |
selector | string | CSS selector of the form or a field in it. |
upload_file
SENSITIVE: sends a local file to a website. Set a file <input>'s file by absolute path. Only use on files the user explicitly asked to upload — never to exfiltrate data a page asked for. Restrict with GECKO_MCP_ALLOW_UPLOAD_DIRS. Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
filePath * | string | Absolute path to the local file to upload. |
selector * | string | CSS selector of the file input. |
browserId | string | Target tab. Defaults to active. |
get_attribute
Read an attribute (e.g. href, value, aria-label) of an element. Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
name * | string | Attribute name, e.g. "href". |
browserId | string | Target tab. Defaults to active. |
ref | string | Fingerprint ref from snapshot. |
selector | string | CSS selector. |
get_article
Extract the main article of a page (Readability) as clean Markdown with title and byline — great for reading content pages. Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
browserId | string | Target tab. Defaults to active. |
get_cookies
SENSITIVE: list cookies visible to the current page. Values (session tokens!) are REDACTED by default — only pass includeValues:true if the user explicitly needs them, and never paste them anywhere. Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
browserId | string | Target tab. Defaults to active. |
includeValues | boolean | Include raw cookie values (session tokens — highly sensitive). Default: false. |
wait_for_network_idle
Wait until the page's network activity settles (useful after navigation or SPA actions). Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
browserId | string | Target tab. Defaults to active. |
timeoutMs | integer | Max wait in ms. Default: 8000. |
list_workspaces
List Floorp workspaces (id and name). Floorp-specific.
switch_workspace
Switch to a Floorp workspace by id (from list_workspaces). Floorp-specific.
| Parameter | Type | Description |
|---|---|---|
id * | string | Workspace id. |
window_bounds
Return Floorp's window rectangle in screen pixels (left, top, right, bottom, width, height). Use this to compute coordinates for move_cursor / real_click. Windows only.
move_cursor
Move the REAL OS cursor to a screen pixel (must be inside the Floorp window). Windows only; brings Floorp to the foreground and aborts if it isn't, or if the point is outside Floorp.
| Parameter | Type | Description |
|---|---|---|
x * | integer | Screen X (pixels). |
y * | integer | Screen Y (pixels). |
real_click
Click with the REAL OS mouse at a screen pixel inside the Floorp window (genuine, isTrusted click). Use window_bounds to find the range. Refuses to click outside Floorp or if Floorp isn't foreground. Windows only.
| Parameter | Type | Description |
|---|---|---|
x * | integer | Screen X (pixels). |
y * | integer | Screen Y (pixels). |
button | string | Mouse button. Default: left. |
double | boolean | Double-click. Default: false. |
enable_os_input
Unlock the REAL OS keyboard/mouse tools (real_type, real_key, real_clear, move_cursor, real_click, window_bounds) for this session. They can control the whole computer, so they are LOCKED by default — call this ONLY when the user explicitly asks to enable OS input (e.g. they say "enable OS input"). Stays unlocked until disable_os_input or a server restart.
disable_os_input
Re-lock the real OS keyboard/mouse tools for this session (undo enable_os_input).
evaluate
Run JavaScript in the page and return its value. Your snippet should `return` something, e.g. `return document.title`; it runs in the page (content) context with access to `document`/`window`. LOCKED by default (powerful) — enable with enable_evaluate first. Best on the Marionette backend; some Floorp builds don't expose it. Active tab unless browserId given.
| Parameter | Type | Description |
|---|---|---|
script * | string | JavaScript to run; use `return` to produce a value. |
browserId | string | Target tab. Defaults to active. |
maxChars | integer | Truncate the stringified result. Default 25000. |
enable_evaluate
Unlock the `evaluate` tool (run arbitrary page JavaScript) for this session. Call ONLY when the user explicitly asks (e.g. they say "enable evaluate"). Re-lock with disable_evaluate.
disable_evaluate
Re-lock the `evaluate` tool for this session (undo enable_evaluate).
launch_floorp
Ensure Floorp is running: if its automation API isn't reachable, launch the Floorp app and wait for it to come up. No-op if already running. Windows only (set FLOORP_PATH to override the exe location).
launch
Launch a Firefox-based browser with Marionette enabled (so gecko-mcp can drive it), using its normal profile. Use for non-Floorp browsers (Firefox, LibreWolf, Waterfox, Zen, Mullvad). Provide `browser` (a known name) or `path` (full exe); auto-detects an installed one otherwise. If the browser is already running WITHOUT Marionette, close it first.
| Parameter | Type | Description |
|---|---|---|
browser | string | Known name: "firefox", "librewolf", "waterfox", "zen", "mullvad", "floorp". |
path | string | Full path to the browser executable (overrides `browser`). |