browser-mcp-2026.mdupdated 2026-07-164536 words
ダブルクリックで英日反転
Applied Sciences · Engineering

Browser Automation MCP 2026 — Playwright, chrome-devtools, agent-browser

EN

Three MCP (Model Context Protocol) servers let AI agents drive a browser. They differ sharply in token cost, ability to reuse authenticated sessions, and maturity — picking the right one changes task economics dramatically.

How screen state reaches the LLM

  • Screenshot (vision): 5,000–8,000 tok per image — most expressive, most expensive
  • Full HTML: tens of thousands of tokens — rarely practical
  • Accessibility tree (DOM semantic tree): 200–12,000 tok — the mainstream approach
  • Accessibility tree + compact refs: 200–400 tok — agent-browser's approach, least expensive

Playwright MCP (Microsoft official)

  • Uses accessibility snapshot by default; tool-schema init costs ~13,700 tok
  • Per-snapshot: 3,800–12,000 tok; full test measured at ~114,000 tok
  • Best fit: E2E testing, CI/CD, SaaS smoke checks — mature and stable
  • Weakness: hard to reuse an already-authenticated Chrome session

chrome-devtools-mcp (Google official) — best for authenticated sites

  • Attaches via CDP (Chrome DevTools Protocol) to an existing Chrome process
  • Reuses live sessions (government portals, banks, internal tools) without re-login
  • Tool-schema init ~17,000 tok but whole-task cost reported 78% lower than Playwright
  • Also an official Anthropic Claude plugin; Chromium-only (no Firefox)

agent-browser-mcp (Vercel Labs) — best for long autonomous loops

  • Returns only actionable elements with stable refs — 200–400 tok per page (~1/30 of Playwright)
  • Same context budget allows 5.7× more actions than Playwright MCP
  • Ideal for multi-hundred-step autonomous workflows (e.g. Ralph Wiggum Loop)
  • Caveat: released early 2026, few production deployments; MCP wrapper is community-built
Default to chrome-devtools-mcp for auth-required work; switch to agent-browser-mcp for long autonomous loops; use Playwright MCP for testing pipelines.
Applied Sciences · Engineering

ブラウザ自動化 MCP 2026 — Playwright・chrome-devtools・agent-browser 比較

JP

AIエージェントが​ブラウザを​操作する​ための​MCP​(Model Context Protocol=AIと​ツールを​つなぐ​標準プロトコル)​サーバーは​3系統ある。​トークン消費量・認証済みセッションの​再利用可否・成熟度が​大きく​異なり、​選択次第で​コストが​劇的に​変わる。

画面状態を​LLMに​伝える​4つの​方​法

  • スクリーンショット​(vision)​: 1枚5,000〜8,000 tok — 表現力は​最高、​コストも​最高
  • フルHTML: 数万 tok — 現実的でない​ケースが​多い
  • アクセシビリティツリー​(DOMの​意味構造木)​: 200〜12,000 tok — 現在の​主流
  • ツリー+コンパクト参照: 200〜400 tok — agent-browserの​手法、​最も​軽量

Playwright MCP​(Microsoft公式)

  • アクセシビリティスナップショット採用。​ツール定義スキーマ初期化で​約13,700 tok
  • スナップショット1回3,800〜12,000 tok、​テスト全体で​約114,000 tokを​計測
  • 最適用途: E2Eテスト・CI/CD・SaaSの​疎通確認 — 成熟・安定
  • 弱点: 既ログイン済みの​Chromeセッションを​再利用しに​くい

chrome-devtools-mcp​(Google公式)​— 認証済みサイトに​最強

  • CDP​(Chrome DevTools Protocol=Chromeの​内部​制御プロトコル)で​既存プロセスに​アタッチ
  • 行政ポータル・銀行・社内ツールなどの​セッションを​ログインなしで​再利用できる
  • スキーマ初期化は​約17,000 tokだが、​タスク全体では​Playwright比78%削減との​報告
  • Anthropic公式Claudeプラグインと​しても​配布。​Chromiumのみ​対応​(Firefox不可)

agent-browser-mcp​(Vercel Labs)​— 長期自律ループに​最適

  • 操作可能な​要素だけを​安定参照IDつきで​返す。​1ページ200〜400 tok​(Playwright比約1/30)
  • 同じ​コンテキスト予算で​Playwright MCPの​5.7倍の​アクションが​可能
  • 数百ステップの​自律ループ​(例: Ralph Wiggum Loop)に​最適
  • 注意: 2026年初リリースで​本番​実績は​少なく、​MCPラッパーは​コミュニティ製
認証が​必要な​業務には​chrome-devtools-mcp、​長期自律ループには​agent-browser-mcp、​テストパイプラインには​Playwright MCPを​使い分けるのが​現時点の​ベストプラクティス。
148 notestil