Skip to main content
Glama
Blinkwire

Blinkwire

Blinkwire

CI npm version license node

A drop-in replacement for Playwright MCP built directly on the Chrome DevTools Protocol. No Playwright, no Puppeteer, no browser download. Blinkwire attaches to a Chrome you already have running and gives an LLM the same tools, with fewer round-trips and far fewer tokens.

playwright-mcp:  spawn browser (~1-3s) → Playwright → CDP → polling actionability → accessibility tree
blinkwire:       attach (0ms) → CDP → 1-4 calls per action → pruned tree

Table of Contents

Related MCP server: Fast Browser MCP

Why it is faster

Playwright MCP

Blinkwire

Startup

launches a browser (1-3 s)

attaches to yours (0 ms)

Deps

Playwright + browser binaries (~400 MB)

ws + MCP SDK

Typing

4 key events per character

direct bulk string insertion (Input.insertText)

Click

scroll + actionability polling (10-30 CDP calls)

1 geometry eval + 3 Input calls

Scroll

synthetic wheel animation

1 eval

Waiting

fixed --timeout-settle sleep

MutationObserver — resolves on the first idle frame

Snapshot

full accessibility dump

interactive/landmark/heading tree, or a diff

Multi-step

N MCP round-trips

1 via browser_batch

Network domain

always on

off by default (--network-capture to enable)

Install

cd blinkwire
npm install
npm run build

Blinkwire finds your Chrome; you don't point it at one

Startup order, first validated hit wins:

  1. --cdp-endpoint, if given

  2. the configured port (default :9222)

  3. any DevToolsActivePort your installed Chrome profiles advertise

  4. a sweep of :9222–:9245

A port is only accepted if /json/version answers with a real Browser string — a browser that owns a port but serves no DevTools (the classic broken-9222 case) is skipped, not attached.

If nothing debuggable exists, Blinkwire fails with guidance instead of silently opening a new browser — your tabs are yours. Pass --launch only when you explicitly want a separate, managed Chrome (it starts on a verified-free port, announces itself on stderr, and shows (Blinkwire-managed) in browser_status).

Your own daily Chrome only becomes visible if you restart it once with a debugging port — Chrome only reads that flag at startup:

# Windows
"C:\Program Files\Google\Chrome\Application\chrome.exe" --remote-debugging-port=9222

# macOS
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --remote-debugging-port=9222

# Linux
google-chrome --remote-debugging-port=9222

Verify without starting a client: blinkwire --check (prints which browser it attached to, then exits).

Running node dist/index.js by hand with no MCP client attached now says so and exits instead of hanging.

Configure your client

Tool names are prefixed browser_ by default, so Blinkwire is a literal drop-in.

opencode (~/.config/opencode/opencode.json)

{
  "mcp": {
    "blinkwire": {
      "type": "local",
      "command": ["node", "C:/Users/You/Projects/blinkwire/dist/index.js"],
      "enabled": true
    }
  }
}

Claude Desktop / Cursor / Cline / VS Code

{
  "mcpServers": {
    "blinkwire": {
      "command": "node",
      "args": ["C:/Users/You/Projects/blinkwire/dist/index.js"]
    }
  }
}

Options

Every flag also reads a BLINKWIRE_* env var (e.g. BLINKWIRE_PORT).

Flag

Default

Purpose

--port, --host

9222, 127.0.0.1

Where Chrome exposes CDP

--cdp-endpoint

—

Full endpoint, e.g. http://127.0.0.1:9222

--launch

off

Opt in to a managed browser when no debuggable one is found (default: attach only, fail otherwise)

--headless

off

Only with --launch

--executable-path

auto

Chrome/Edge binary

--user-data-dir

temp

Profile dir (only used when Blinkwire launches)

--match-url, --match-title, --match-index

—

Which existing tab to attach to

--snapshot-mode

interactive

interactive | full | minimal

--snapshot-boxes

off

Add [box=x,y,w,h] to every node

--max-output-tokens

6000

Hard cap on any single response

--console-level

info

Minimum console severity

--image-responses

allow

omit to suppress inline images

--network-capture

off

Enable the Network domain (slower, but needed for browser_network_requests)

--timeout-settle

500

Max ms to wait for the page to settle

--timeout-tool

60000

Hard ceiling per tool call — a wedged action cannot stall the queue

--check

—

Verify a browser is reachable, print which one, exit

--output-dir

temp dir

Where filename arguments are written

--prefix

browser_

Tool-name prefix

--debug

off

Emit timings into _meta

Tools (56)

Covers the primary Playwright MCP core automation and utility surface, plus a few extras (batch, diff). Playwright code generator (codegen) and verification test wrappers are intentionally omitted in favor of lean execution.

Navigation browser_navigate browser_navigate_back browser_navigate_forward browser_reload browser_wait_for

Reading browser_snapshot browser_find browser_snapshot_diff browser_evaluate

Interaction browser_click browser_hover browser_type browser_press_key browser_select_option browser_drag browser_drop browser_file_upload browser_fill_form browser_handle_dialog

Coordinates browser_mouse_move_xy browser_mouse_click_xy browser_mouse_drag_xy browser_mouse_wheel browser_scroll

Capture browser_take_screenshot browser_pdf_save browser_console_messages browser_network_requests browser_network_request

Tabs & session browser_tabs browser_close browser_resize browser_connect browser_install browser_status browser_get_config

Storage & network browser_cookie_{list,get,set,delete,clear} browser_localstorage_{list,get,set,delete,clear} browser_sessionstorage_{list,get,set,delete,clear} browser_network_state_set browser_route browser_route_list browser_unroute

Extras browser_batch — run N actions in one round-trip.

The three things that save the most

1. browser_batch. One MCP call, N actions, one settle at the end.

{ "steps": [
  { "tool": "click",   "args": { "target": "e7" } },
  { "tool": "type",    "args": { "target": "e3", "text": "blinkwire" } },
  { "tool": "click",   "args": { "target": "e9" } }
]}

→ 1. click ok 4ms / 2. type ok 6ms / 3. click ok 3ms — 3/3 ok, 16ms total

2. browser_snapshot_diff. After an action, see only what changed — usually 3-6 lines instead of a whole tree.

3. browser_find. Locate one element without re-reading the page.

How the speed works

  • One eval per snapshot. The DOM walk, role mapping, naming, ref assignment and rendering all happen in-page inside a single Runtime.evaluate. Nothing is queried node-by-node over CDP.

  • Refs live in the page. Elements are held in window.__bw.els, so e4 resolves to geometry in one round-trip with no DOM-domain traffic.

  • Settle, don't sleep. settle() installs a MutationObserver and resolves on the first idle frame. A static page costs ~1 ms instead of a fixed 500 ms.

  • No DOM domain in the hot path. Only file_upload, resize and selector fallbacks touch it.

  • Fail fast, fail helpfully. Stale refs, invisible elements and unmatched options all return a one-line error naming the fix.

Limits

  • Chromium-family only (Chrome, Edge, Brave). CDP is the whole point.

  • browser_resize needs a browser-level connection; without one it falls back to viewport emulation and says so.

  • Cross-origin iframes are snapshot from the top document only.

  • Network inspection is opt-in because keeping the Network domain enabled measurably slows every navigation.

Development

npm run build     # tsc -> dist/
npm test          # unit tests (node --test + tsx)
npm run test:integration  # smoke + attach suites (spawn real Chrome)
npm run lint
npm run coverage
npm run dev       # watch

Examples

End-to-end via MCP client (tool names use default browser_ prefix):

import { Client } from '@modelcontextprotocol/sdk/client/index.js';

const browser = await Blinkwire.launch();

await browser.browser_navigate({ url: 'https://example.com' });
await browser.browser_click({ target: 'e4' });
await browser.browser_type({ target: 'e3', text: 'user@example.com' });
await browser.browser_click({ target: 'e9' });
await browser.browser_wait_for({ text: 'Dashboard' });

const snapshot = await browser.browser_snapshot();
console.log(snapshot);

await browser.close();

Diff limits

diffText trims common prefix/suffix then LCS on the middle. Once (a.length+1)*(b.length+1) exceeds MAX_DP_CELLS (default 4_000_000, override with BLINKWIRE_MAX_DP_CELLS) it falls back to a cheap set-based diff — very large snapshots stay fast but coarser.

Architecture: src/cdp (transport, discovery, session) → src/core (refs, snapshot, diff, wait, image, budget) → src/tools (one module per tool family) → src/server.ts (MCP wiring).

Available Tools

56 tools
browser_batchRun several actions at onceA

Run several Blinkwire actions in ONE call. This is the biggest latency and context win available: you pay one round-trip instead of N. Each step is {tool, args}. Tool names may be bare ("click") or prefixed (e.g. with your server prefix). By default only failures (and the last step) have their full output inlined — use include to see more.

Inputs: steps (required), settle, include, stopOnError.

browser_clickClickA

Click an element. Pass a ref from browser_snapshot (e.g. "e4") or a CSS selector. Four CDP calls total — no polling.

Inputs: target (required), button, settle, element, +2 more.

browser_closeClose the current tabA
Destructive

Close the current tab. The browser itself is left running — Blinkwire does not own it.

Inputs: no named parameters.

browser_connectConnect to a browser over CDPA

Attach Blinkwire to a Chrome instance exposing the DevTools Protocol. Use this to switch browsers or tabs without restarting the server.

Inputs: host, port, index, matchUrl, +2 more.

browser_console_messagesGet console messagesA
Read-only

Return console output captured since the last navigation. Filter by level or regex to keep it short.

Inputs: all, level, filter.

browser_dragDrag mouseA

Drag and drop from one element to another.

Inputs: endTarget (required), startTarget (required).

browser_dropDrop files or dataA

Drop files or MIME-typed data onto an element, as if dragged in from outside the page.

Inputs: target (required), data, paths.

browser_evaluateEvaluate JavaScriptA

Run JavaScript in the page. Pass an arrow function as a string: "() => document.title". With target, the function receives the element.

Inputs: function (required), target, filename.

browser_file_uploadUpload filesA

Set files on a file input. Point target at the input, or omit it to use the first file input on the page.

Inputs: paths (required), target.

browser_fill_formFill formA

Fill many form fields in ONE call. This is the fastest way to complete a form — one MCP round-trip and one settle for the whole form.

Inputs: fields (required), settle.

browser_findFind in page snapshotA
Read-only

Search the current snapshot for text or a regex and return matching lines with their refs. Far cheaper than re-reading the whole snapshot when you only need to locate one element.

Inputs: text, regex, context.

browser_get_configGet configA
Read-only

Return the resolved configuration after merging CLI flags and environment variables.

Inputs: no named parameters.

browser_handle_dialogHandle a dialogA

Accept or dismiss a pending JavaScript dialog (alert, confirm, prompt or beforeunload). Call it right after the action that opened the dialog.

Inputs: accept (required), promptText.

browser_hoverHoverA

Move the mouse over an element. Use it to reveal hover menus before clicking.

Inputs: target (required), element.

browser_installShow CDP setup instructionsA
Read-only

Nothing to install. Blinkwire attaches to a Chrome you already run, so there is no browser download. Prints the exact setup steps.

Inputs: no named parameters.

browser_localstorage_clearClear localStorageA

Remove every localStorage key for the current origin.

Inputs: no named parameters.

browser_localstorage_deleteDelete localStorage itemC

Remove one localStorage key.

Inputs: key (required).

browser_localstorage_getGet localStorage itemB
Read-only

Read one localStorage key.

Inputs: key (required).

browser_localstorage_listList localStorageA
Read-only

List all localStorage key-value pairs for the current origin.

Inputs: no named parameters.

browser_localstorage_setSet localStorage itemA

Write one localStorage key.

Inputs: key (required), value (required).

browser_mouse_click_xyClick at coordinatesA

Click at viewport coordinates. Prefer browser_click with a ref — coordinates break when the layout shifts.

Inputs: x (required), y (required), button, doubleClick.

browser_mouse_drag_xyDrag between coordinatesC

Drag from one viewport coordinate to another.

Inputs: toX (required), toY (required), fromX (required), fromY (required).

browser_mouse_move_xyMove mouseA

Move the mouse to viewport coordinates (CSS pixels).

Inputs: x (required), y (required).

browser_mouse_wheelScroll with the wheelA

Dispatch a wheel event. Prefer browser_scroll — it is a single round-trip instead of a synthetic scroll animation.

Inputs: deltaX, deltaY.

browser_navigateNavigate to a URLA

Navigate to a URL and wait for the page to settle. Resolves on the load event (or the SPA history event) instead of a fixed sleep.

Inputs: url (required).

browser_navigate_backGo backA

Go back to the previous page in the history.

Inputs: no named parameters.

browser_navigate_forwardGo forwardA

Go forward to the next page in the history.

Inputs: no named parameters.

browser_network_requestShow network request detailsA
Read-only

Show the headers and body of a single request, by the number printed by browser_network_requests.

Inputs: index (required), part.

browser_network_requestsList network requestsA
Read-only

List requests made since the page loaded. Off by default — restart with --network-capture if you need it (the Network domain is expensive).

Inputs: limit, filter, static.

browser_network_state_setSet network stateA

Go offline or back online. Useful for testing error paths.

Inputs: state (required).

browser_pdf_saveSave as PDFA
Read-only

Print the current page to a PDF file.

Inputs: scale, format, filename, landscape, +1 more.

browser_press_keyPress a keyA

Press a key or a modifier combo, e.g. "Enter", "ArrowLeft", "Control+A", "Shift+Tab".

Inputs: key (required), modifiers.

browser_reloadReload the pageA

Reload the current page.

Inputs: ignoreCache.

browser_resizeResize browser windowA

Resize the browser window. Uses the real window bounds when a browser-level CDP connection is available, otherwise emulates the viewport.

Inputs: width (required), height (required).

browser_routeMock network requestsA

Stub responses for URLs matching a pattern. Restart mocking by re-adding the route.

Inputs: pattern (required), body, status, headers, +1 more.

browser_route_listList network routesA
Read-only

Show the active mocked routes.

Inputs: no named parameters.

browser_scrollScroll the pageA

Scroll the page or an element. ONE round-trip (no synthetic wheel events), and it reports whether you hit the end.

Inputs: x, y, amount, target, +1 more.

browser_select_optionSelect optionA

Select one or more options in a . One CDP call — sets the value and fires input/change.

Inputs: target (required), values (required), element.

browser_sessionstorage_clearClear sessionStorageA

Remove every sessionStorage key for the current origin.

Inputs: no named parameters.

browser_sessionstorage_deleteDelete sessionStorage itemA

Remove one sessionStorage key.

Inputs: key (required).

browser_sessionstorage_getGet sessionStorage itemC
Read-only

Read one sessionStorage key.

Inputs: key (required).

browser_sessionstorage_listList sessionStorageA
Read-only

List all sessionStorage key-value pairs for the current origin.

Inputs: no named parameters.

browser_sessionstorage_setSet sessionStorage itemC

Write one sessionStorage key.

Inputs: key (required), value (required).

browser_snapshotPage snapshotA
Read-only

Capture a compact, ref-tagged snapshot of the page. This is the primary way to read a page — cheaper and more reliable than a screenshot. Refs ([ref=eN]) are what you pass to click/type/hover.

Inputs: mode, boxes, depth, target, +1 more.

browser_snapshot_diffDiff snapshotsA
Read-only

Show only what changed since the last snapshot. The cheapest way to check the effect of an action — usually a handful of lines instead of a whole tree.

Inputs: contextLines.

browser_statusConnection statusA
Read-only

Show the attached browser, active target and buffer sizes. Cheap diagnostic — call it first when something looks wrong.

Inputs: no named parameters.

browser_tabsManage tabsA

List, create, close or select a browser tab. Prefer select over new when a matching tab already exists.

Inputs: action (required), url, index.

browser_take_screenshotTake a screenshotA
Read-only

Capture the page as an image. Screenshots cost a lot of context — prefer browser_snapshot, and use this only when you need to see pixels.

Inputs: type, scale, target, quality, +3 more.

browser_typeType textA

Type text into an editable element. Fast path focuses and inputs text in bulk (Input.insertText) without per-character key events — use slowly:true only when the page needs real per-key events.

Inputs: text (required), target (required), settle, slowly, +2 more.

browser_unrouteRemove network routesA

Remove one mocked route, or all of them when no pattern is given.

Inputs: pattern.

browser_wait_forWait forA

Wait for text to appear or disappear, or for a fixed time. Uses a MutationObserver, so it returns the instant the text shows up.

Inputs: text, time, timeout, textGone.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.4/5.0

    Scored across 56 tools

    Disambiguation4/5

    Most tools have distinct purposes, and overlapping actions are differentiated by target (element vs coordinates) or scope (single vs all). A few pairs like browser_close and browser_tabs could be confused, but descriptions are clear enough.

    Naming Consistency3/5

    All tools share the browser_ prefix and snake_case, but the verb/noun ordering is inconsistent: browser_navigate and browser_click are verb-first, while browser_cookie_list and browser_localstorage_get are noun-first. This makes the naming pattern somewhat predictable but not fully uniform.

    Tool Count1/5

    With 56 tools, the surface is far beyond the typical well-scoped range and crosses the 50+ extreme threshold. Many low-level operations could be consolidated or hidden behind higher-level actions.

    Completeness5/5

    The toolset covers the main browser automation needs: navigation, interaction, forms, snapshots, storage, network, tabs, cookies, console, and batch operations. It is hard to identify a major missing capability for general browser automation.

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      A token-efficient browser automation server that enables LLMs to navigate websites, click elements, and extract content using accessibility trees and markdown conversion. It provides eight tools for lightweight browser interaction optimized for performance with local LLM endpoints.
      MIT
    • A
      license
      B
      quality
      B
      maintenance
      Enables AI agents and developers to automate real Chrome/Chromium browsers through the Chrome DevTools Protocol, with token-efficient snapshots, multi-action batching, shadow DOM traversal, system-page control, extension management, and network/WebSocket inspection.
      81
      1
      MIT
    • F
      license
      Not graded
      quality
      A
      maintenance
      Enables AI agents to browse and interact with websites through a persistent headless Chromium session, returning compact structured page representations instead of full accessibility-tree dumps. Agents can navigate, query specific elements and forms, click, type, manage tabs and cookies, and monitor console or network activity while paying a fraction of the tokens.
      4 npm
      -