Sponsored byOutsenseAI that finds your next clients
SponsorGROUOutbound, LinkedIn content and leads for B2B teamsSponsorOutsenseAI that finds your next clientsAd+Your tool hereSeen by people installing AI tools@Weekly picksThe best new tools, one email a week

Playwright cli

Plugin by microsoft

Automates browser interactions and web page tests from the command line, using Playwright. Built for coding agents such as Claude Code and GitHub Copilot, it exposes CLI commands as skills.

  • Score 89
  • 16k stars
  • Apache-2.0
  • Updated
Works withClaude Code

Install Playwright cli

Built from the published package, never by AI.

/plugin marketplace add lpx0312/myai-plugins
/plugin install playwright-cli@myai-plugins

Type both lines inside Claude Code: the first adds the marketplace, the second installs the plugin.

Step-by-step: install Playwright cli in Claude Code

Skills can run scripts on your machine. Some need an API key: check the README.

About

playwright-cli is a command line interface to Playwright, installed from the npm package @playwright/cli. It lets coding agents open pages, navigate, click, type, fill forms, take snapshots and screenshots, and manage cookies and browser storage through concise commands. The source says this approach is token-efficient because it does not load large tool schemas or accessibility trees into the model context.

After a global install, running playwright-cli install --skills adds the skills to Claude Code, GitHub Copilot or other agents. Sessions keep browser state separate for each project, and the open command can run headed so you can watch the browser. A monitoring dashboard started with the show command lets you observe running sessions or take over input. It is aimed at developers and coding agents that run browser automation and tests on web pages.

Written from the project's README and checked against it.

What it can do

  • Page navigation and interactionOpen, navigate, click, double click, type, fill, hover, drag and select elements on a page.
  • Snapshots and searchCapture page snapshots to get element refs and search the snapshot for text or a regex.
  • Screenshots and PDFSave screenshots of the page or an element, and save pages as PDF files.
  • TabsList, create, select and close browser tabs, including isolated contexts.
  • Storage managementSave and load storage state, and manage cookies, localStorage and sessionStorage.
  • EmulationEmulate color scheme, reduced motion, forced colors, contrast and CSS media type.
  • Network mockingMock network requests with the route command.
  • SessionsRun separate browser sessions per project, list them, and close or kill them.
  • Monitoring dashboardOpen a visual dashboard to see and control running browser sessions.
  • Skills installationInstall the skills into Claude Code, GitHub Copilot or other agent skill folders.

What you need

  • Node.js 20 or newer
  • Claude Code, GitHub Copilot or another coding agent

Try asking

  • Test the add todo flow on https://demo.playwright.dev/todomvc using playwright-cli.
  • Open example.com headed and take a full-page screenshot.
  • Save the cookies and localStorage of my session to a file.

Good to know

  • Headless by default. Use --headed to see the browser.
  • The browser profile is kept in memory unless --persistent is used, so it is lost when the browser closes.
  • A headless session shuts down after an hour without commands.

Security check

A

No download-and-run commands, hidden instructions or signs of sending keys out were found.

Checked automatically: README.md. This looks for known risky patterns and is not a full audit. How grades work

Alternatives to Playwright cli

All alternatives →
Chrome devtools mcpChromeDevTools
95

Chrome DevTools MCP lets coding agents control and inspect a live Chrome browser. It records performance traces, analyzes network requests, and checks console messages. It is for developers who want their assistant to debug and automate web pages.

AAB 60k
Agent browservercel-labs
89

agent-browser gives AI agents a browser they drive one shell command at a time. The agent reads a page as compact text with element refs, acts on them, and checks the result. It suits AI agents and developers who need browser automation in Chromium.

AAB 54k
Playwright mcpmicrosoft
89

Gives AI assistants browser automation through Microsoft's Playwright MCP server, using accessibility snapshots instead of screenshots. Suited to exploratory automation, self-healing tests and long-running browser workflows.

AAB 40k
Chrome devtools mcpChromeDevTools
89

Chrome DevTools for agents gives a coding assistant control of a live Chrome browser through an MCP server and a CLI. It suits developers who want browser automation, debugging and performance analysis.

AAB 60k
Microsoft playwright mcpmicrosoft
89

Playwright MCP is Microsoft's Model Context Protocol server for browser automation with Playwright. It lets AI assistants control web pages through structured accessibility snapshots, for debugging and test automation.

AAB 40k
Agent browservercel-labs
89

Agent browser is a native Rust CLI that lets an AI agent open pages, read them as an accessibility tree, and act on elements from the shell. It suits developers building browser automation for AI agents.

AAB 54k

Compare with Chrome devtools mcp, Agent browser or Playwright mcp

Playwright cli: common questions

Does playwright-cli work with MCP?

The source says the CLI is the best fit for coding agents, and it compares it with Playwright MCP, which it says suits specialized loops that need persistent state. It links to the Playwright MCP project for more information.

Which agents can use the skills?

The source says Claude Code, GitHub Copilot and other coding agents can use the locally installed skills. Skills install into .claude/skills by default, or into .agents/skills with the agents option.

Can I watch what the agent is doing in the browser?

Yes. The open command accepts --headed to show the browser, and the show command starts a dashboard with a live view of running sessions.

How do I install Playwright cli?

Inside Claude Code, add the marketplace with /plugin marketplace add lpx0312/myai-plugins, then install the plugin with the second command shown above.

Is Playwright cli free?

The code is published under the Apache-2.0 licence. The service it connects to may have its own pricing.

Is Playwright cli safe to use?

It scores 89 of 100. Grades: maintenance A, licence A, quality B. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.

What are alternatives to Playwright cli?

Similar plugins: Chrome devtools mcp, Agent browser, Playwright mcp, Chrome devtools mcp.

Playwright cli Install

Add to stack

Loading.