MP

microsoft/playwright-mcp

Developer tools公式

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る

3.9万 stars 3347 forks 品質 98 トレンド 99Apache-2.0

劇作家MCPサーバー

概要

Playwrightを用いてブラウザ自動化機能を提供するモデルコンテキストプロトコル(MCP)サーバーです。このサーバーにより、LLMはスクリーンショットや視覚的に調整されたモデルを回避し、構造化されたアクセシビリティスナップショットを通じてウェブページとやり取りできます。 このパッケージはPlaywrightへのMCPインターフェースを提供します。もしを使っている場合は、代わりにCLI+SKILLSを使うと良いかもしれません。 - : 現代では、CLIの呼び出しがトークン効率が高いため、CLIベースのワークフローをMCPよりもSKILLとして公開することが推奨されています。これにより、大規模なツールスキーマや冗長なアクセシビリティツリーをモデルコンテキストにロードする必要がなく、エージェントは簡潔で目的づきのコマンドで動作できます。これにより、CLI+SKILLはブラウザの自動化と大規模なコードベース、テスト、推論を限られたコンテキストウィンドウ内で両立させる必要がある高スループットのコーディングエージェントにより適しています。.

概要(AI 翻訳)

劇作家MCP

Playwrightを用いてブラウザ自動化機能を提供するモデルコンテキストプロトコル(MCP)サーバーです。このサーバーにより、LLMはスクリーンショットや視覚的に調整されたモデルを回避し、構造化されたアクセシビリティスナップショットを通じてウェブページとやり取りできます。

劇作家MCP対劇作家CLI

このパッケージはPlaywrightへのMCPインターフェースを提供します。もしコーディングエージェントを使用している場合は、CLI+SKILLSを使うと良いかもしれません。

  • CLI:現代のコーディングエージェントは、CLI呼び出しがトークン効率が高いため、MCPよりもSKILLとして公開されたCLIベースのワークフローをますます好む傾向があります。これにより、大規模なツールスキーマや冗長なアクセシビリティツリーをモデルコンテキストにロードする必要がなく、エージェントは簡潔で目的づきのコマンドで動作できます。これにより、CLI+SKILLは、ブラウザの自動化と大規模なコードベース、テスト、推論を限られたコンテキストウィンドウ内で両立させる必要がある高スループットのコーディングエージェントにより適しています。Playwright CLIについてSKILLSでさらに学びましょう。

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。

README

以下は原文 README の抜粋です。原文を見る。

Playwright MCP

A Model Context Protocol (MCP) server that provides browser automation capabilities using Playwright. This server enables LLMs to interact with web pages through structured accessibility snapshots, bypassing the need for screenshots or visually-tuned models.

Playwright MCP vs Playwright CLI

This package provides MCP interface into Playwright. If you are using a coding agent, you might benefit from using the CLI+SKILLS instead.

  • CLI: Modern coding agents increasingly favor CLI–based workflows exposed as SKILLs over MCP because CLI invocations are more token-efficient: they avoid loading large tool schemas and verbose accessibility trees into the model context, allowing agents to act through concise, purpose-built commands. This makes CLI + SKILLs better suited for high-throughput coding agents that must balance browser automation with large codebases, tests, and reasoning within limited context windows.Learn more about Playwright CLI with SKILLS.

  • MCP: MCP remains relevant for specialized agentic loops that benefit from persistent state, rich introspection, and iterative reasoning over page structure, such as exploratory automation, self-healing tests, or long-running autonomous workflows where maintaining continuous browser context outweighs token cost concerns.

Key Features

  • Fast and lightweight. Uses Playwright’s accessibility tree, not pixel-based input.
  • LLM-friendly. No vision models needed, operates purely on structured data.
  • Deterministic tool application. Avoids ambiguity common with screenshot-based approaches.

Requirements

  • Node.js 18 or newer
  • VS Code, Cursor, Windsurf, Claude Desktop, Goose, Grok, Junie or any other MCP client

Getting started

First, install the Playwright MCP server with your client.

Standard config works in most of the tools:

{
  "mcpServers": {
    "playwright": {
      "command": "npx",
      "args": [
        "@playwright/mcp@latest"
      ]
    }
  }
}

GitHub で README 全文を見る

インストール

npx @playwright/mcp@latest
MCP 初心者?mcpskill.org のガイドから始めましょう →

設定

{ "mcpServers": { "playwright": { "command": "npx", "args": [ "@playwright/mcp@latest" ] } } }