microsoft/playwright
50.5
Adequate · 28 September 2026
150.6k
lines of production code
TypeScript
with JavaScript
4
measurements over time
What this system is
This system is Playwright, a framework for browser automation and end-to-end testing across Chromium, Firefox, and WebKit. It provides a comprehensive API for controlling browsers, recording user interactions, and generating test scripts in multiple languages. The system also includes tooling for AI-assisted test generation, visual regression analysis, and detailed trace viewing for debugging failures.
How it got here
2019–2021 — monorepo scaffolding and browser integration
68 changes.
This period established the Playwright monorepo structure, defining the core package architecture and separating the test runner into its own module. It focused on integrating browser automation capabilities by implementing the Juggler protocol for Firefox, adding CDP interception for WebKit, and building native embedders for macOS and Windows. The work also included setting up comprehensive tooling for documentation, type generation, and dependency management across Linux, Windows, and Android platforms.
2022–2023 — UI modernization and test runner refactoring
46 changes.
This period focused on modernizing the Playwright UI by migrating the Recorder and Trace Viewer to Vite and React 18, while establishing a shared web component library with system theme support. Simultaneously, the test runner infrastructure was significantly refactored into a modular, bundled architecture with explicit dependency management and plugin-based extensibility. The work also included separating browser binaries into dedicated npm packages and expanding test coverage for installation, accessibility, and performance stability.
2024–2026 — MCP, AI agents, and browser extension integration
55 changes.
This period focused on integrating Playwright with external automation ecosystems, introducing a Model Context Protocol (MCP) server, a Chrome extension for browser-based AI control, and a new AI agent system for test generation. It also established a modular backend architecture for CLI and dashboard tools, while expanding test coverage for these new features and adding support for WebDriver BiDi and WebKit WebView.
Features
Add 'Copy as cURL' and 'Copy as fetch' options for network requests
The Trace Viewer now allows users to copy network requests as executable cURL commands or JavaScript fetch calls. This new capability, implemented in the third-party devtools integration, parses the request URL, headers, and body to generate platform-specific shell commands (handling Windows and POSIX escaping) or browser-compatible fetch syntax, making it easier to reproduce captured network activity outside the browser.
_packages/trace-viewer/src/third\party · high confidence
Add Firefox RemoteDebuggingPipe component for external communication
This change introduces the \nsIRemoteDebuggingPipe\ XPCOM component within the Firefox juggler patch suite. It establishes a singleton pipe service that facilitates message passing between the browser process and an external client (such as a test runner) via file descriptors on Unix or named pipes on Windows. The implementation includes the IDL interface, C++ source handling asynchronous read/write threads, and build configuration files (\moz.build\, \components.conf\) to register the component, enabling the underlying remote debugging infrastructure to function.
_browser\patches/firefox/juggler/pipe · high confidence
Add Firefox headless screencast capture capability
This change introduces the core C++ implementation for capturing browser windows in headless Firefox mode. It adds a new \HeadlessWindowCapturer\ component that hooks into the headless widget's snapshot listener to extract raw frame data, converts it to I420 format using libyuv, and feeds it into the existing WebRTC-based screencast service pipeline. This enables automated tools to record video of headless browser sessions.
_browser\patches/firefox/juggler/screencast · high confidence
Add Firefox upstream configuration and ignore rules
The browser\_patches/firefox directory now includes a .gitignore file to exclude the /checkout directory and a new UPSTREAM\_CONFIG.sh script that defines the remote URL, base branch (release), and base revision for the Firefox upstream source.
_browser\patches/firefox · high confidence
Add Playwright embedder build configuration and macOS toolbar component
This change introduces the build infrastructure and a specific UI component for the Playwright browser embedder. It adds Xcode configuration files (Base.xcconfig, DebugRelease.xcconfig, Playwright.xcconfig, SDKVariant.xcconfig) that define compiler standards, deployment targets, and SDK settings for the Playwright target. It also adds a Makefile to conditionally build the project on macOS 10.6 and later, and implements MBToolbarItem, a custom NSToolbarItem subclass used within the Playwright macOS interface.
_browser\_patches/webkit/embedder/Playwright, browser\patches/webkit/embedder/Playwright/Configurations · high confidence
Add Playwright test configuration and MCP server setup for TodoMVC example
The TodoMVC example now includes a dedicated Playwright test configuration (playwright.config.ts) that sets up Chromium testing with HTML and list reporters, video recording with action and test status overlays, and CI-aware retry/worker settings. Additionally, an MCP server configuration (.mcp.json) is added to enable the Playwright test MCP server via npx, and a .gitignore file is introduced to exclude node\_modules, test results, reports, and lockfiles from version control.
examples/todomvc · high confidence
Add VS Code codicon font and color theme variables
The web package now includes the VS Code codicon font and its associated CSS color variables, enabling consistent iconography and theming across the UI components that rely on these assets.
_packages/web/src/third\party · high confidence
Add WebP image encoding and decoding support
The \packages/utils/webp\ module now provides synchronous WebP encode and decode capabilities backed by a bundled libwebp WebAssembly build. Users can convert RGBA image buffers to WebP format with configurable quality and lossless options, and decode WebP buffers back to RGBA data. The module also includes a utility to detect whether a WebP bitstream is lossless by parsing its RIFF header.
packages/utils/webp · high confidence
Add Windows build and embedder for Playwright
Introduces the CMake build configuration and source files for the Playwright browser embedder on Windows. This includes the main entry point, window management, toolbar and URL bar UI, WebKit view integration, and command-line argument parsing (e.g., --headless, --user-data-dir, --disable-accelerated-compositing), enabling Playwright to run as a native Windows application.
_browser\patches/webkit/embedder/Playwright/win · high confidence
Add macOS Playwright browser embedder
Introduces a new native macOS application for Playwright, including the \BrowserWindowController\ for managing the UI and navigation, \AppDelegate\ for handling startup arguments (such as \--user-data-dir\, \--proxy\, and \--headless\), and the necessary XIB interface files and CMake build configuration to compile the \Playwright\ executable.
_browser\patches/webkit/embedder/Playwright/mac · high confidence
Add macOS Playwright.app Xcode project and scheme
The Playwright embedder for macOS now includes a complete Xcode project (Playwright.xcodeproj) and a shared scheme, enabling developers to build, run, debug, and archive the Playwright.app directly within Xcode. This project configures the necessary source files, resources, and frameworks (including WebKit and SecurityInterface) to produce the application bundle.
_browser\patches/webkit/embedder/Playwright/Playwright.xcodeproj · high confidence
Added C\# interface template for API generation
A new C\# interface template file has been added to the doclint utilities, providing the structural basis for generating .NET API code from Markdown documentation. This template includes standard Microsoft Playwright namespaces and attributes, serving as the foundation for the generated client library interfaces.
utils/doclint/templates · high confidence
Added mock Battery API demo application
A new example project has been added to demonstrate the Battery Status API. This demo application visualizes battery level, charging status, and estimated time to full or empty, providing a concrete reference for implementing battery-related features in web applications.
examples/mock-battery/demo-battery-api · high confidence
Added utility to map Linux browser dependencies to distribution packages
A new script (run.sh) and supporting files have been added to the utils/linux-browser-dependencies directory to help maintain a mapping between shared libraries required by Playwright browsers and the specific packages that provide them on various Linux distributions. The script launches a Docker container for a specified distribution (e.g., ubuntu:bionic), installs Playwright browsers, and uses apt-file to reverse-search for the packages providing any missing dependencies, saving the results to a RUN\_RESULT file. This tool aids in ensuring browser dependencies are correctly identified and installed on user systems.
utils/linux-browser-dependencies · high confidence
Android driver build infrastructure and test suite added
The Android driver module now includes the necessary Gradle build files (including Gradle 8.7 wrapper), ProGuard rules, and Android application resources (manifest, launcher icons) to compile the driver app. Additionally, a comprehensive instrumented test suite (InstrumentedTest.java) has been added to verify UI automation capabilities such as element selection, clicking, filling text, dragging, and flinging on Android devices.
packages/playwright-core/src/server/android/driver · high confidence
Browser-compatible Playwright client with Node.js polyfills
The Playwright client library now supports execution in web browsers by introducing a new \connect\ entry point that establishes a WebSocket connection to a Playwright server, and by providing a set of Node.js environment stubs (for modules like \fs\, \path\, \crypto\, and \process\) to ensure compatibility with browser-based bundlers.
packages/playwright-client/src · high confidence
CLI tool to compact CI test results into a local DuckDB database
A new command-line interface has been added to the \utils/test-results-db\ directory to manage a local DuckDB database of CI test results. The tool provides commands to download a pre-built database artifact from GitHub, ingest new Parquet report artifacts from the last 7 days (with configurable lookback and concurrency), and truncate the database to keep only the most recent runs while compacting the file to reclaim disk space. This allows developers to query historical test results locally without relying on remote CI artifacts.
utils/test-results-db · high confidence
Chromium server implementation files added
The core Chromium browser server implementation files have been added to the codebase, including the main browser launcher, connection handling, page management, and protocol helpers. This establishes the foundational server-side code for controlling Chromium-based browsers through the Chrome DevTools Protocol.
packages/playwright-core/src/server/chromium · high confidence
Code generation now supports Python, Java, and C\#
The code generator in the isomorphic package now includes language generators for Python, Java, and C\#, in addition to the existing JavaScript support. This allows users to record browser interactions and export the resulting test scripts directly in these languages, with specific modes available for popular test runners such as Pytest, JUnit, MSTest, NUnit, and xUnit.
packages/isomorphic/codegen · high confidence
Dashboard annotation mode for UI review
The Dashboard now includes an annotation mode that allows users to capture screenshots of browser pages and draw colored rectangular highlights with text comments. Users can manage multiple annotated frames in a sidebar, edit comments, and export their feedback as a ZIP archive containing the annotated images and an accompanying Markdown file with the review notes.
packages/dashboard/src · high confidence
HTML reporter UI components and filtering logic
The HTML reporter now includes a new \Chip\ component for collapsible sections, a \CopyToClipboard\ utility, and a \GanttChart\ for visualizing test durations. A new \Filter\ class enables advanced test filtering using query syntax (e.g., \p:\, \s:\, \@\, \annot:\), and the \headerView\ now displays test statistics and a settings dialog for theme selection.
packages/html-reporter/src · high confidence
Initial Firefox server implementation via Juggler protocol
Playwright now supports automated testing with Firefox by introducing a new server-side implementation in the \packages/playwright-core/src/server/firefox\ directory. This change adds the core browser driver components—including \ffBrowser.ts\, \ffConnection.ts\, \ffPage.ts\, \ffNetworkManager.ts\, and \ffInput.ts\—which communicate with Firefox using the Juggler protocol. This enables full browser control capabilities such as page navigation, network interception, input simulation, and context management for Firefox, bringing it to feature parity with the existing Chromium and WebKit implementations.
packages/playwright-core/src/server/firefox · high confidence
Initial WebDriver BiDi implementation for Chromium and Firefox
Playwright now supports the WebDriver BiDi protocol for Chromium and Firefox, providing an alternative to the legacy CDP and Marionette transports. This change introduces new server-side components (BidiBrowser, BidiChromium, BidiFirefox, BidiConnection, etc.) that handle session management, input actions, network interception, and JavaScript execution via the BiDi standard. For Chromium, it uses a 'BiDi over CDP' bridge, while Firefox uses its native BiDi support. This enables users to leverage BiDi features like improved navigation events, better worker support, and standardized input handling.
packages/playwright-core/src/server/bidi · high confidence
Initial repository scaffolding and project configuration
The repository has been initialized with foundational configuration files, including an .editorconfig for consistent code formatting (2-space indentation, LF line endings), a .gitattributes file to enforce LF line endings for text files (ensuring golden file test stability) and mark JavaScript files as non-linguist-detectable on GitHub, and standard project documentation files (README, CONTRIBUTING, LICENSE, NOTICE, SECURITY, SUPPORT, CODE\_OF\_CONDUCT). Additionally, an ESLint configuration (eslint.config.mjs) and a CLAUDE.md guide for AI agent development workflows have been added to establish coding standards and development practices.
(repo-wide) · high confidence
Introduce AI agent definitions and generators for Playwright test automation
This change adds a new agent system to Playwright, enabling AI coding assistants (Claude, Codex, Opencode) to automatically generate, plan, and fix browser tests. It introduces a parser for agent specifications (YAML front matter with instructions and examples), generators that scaffold the necessary configuration files (like .mcp.json, .claude/agents, .codex/agents) and prompt files for these assistants, and pre-defined agent definitions for test planning, generation, and healing workflows.
packages/playwright/src/agents · high confidence
Introduce Juggler automation framework for Firefox
Adds the Juggler automation framework to Firefox, enabling remote control of the browser via a JSON-RPC protocol over a named pipe. This implementation includes a new \ChannelEventSink\ to monitor network redirects, a \NetworkObserver\ for request interception and response tracking, a \TargetRegistry\ to manage browser contexts and page targets, and a \SimpleChannel\ for cross-process messaging. The framework registers as an XPCOM component and JSWindowActor, allowing external clients to automate browser sessions, manage downloads, and interact with network traffic.
_browser\patches/firefox/juggler · high confidence
Introduce Juggler content-process instrumentation for Firefox automation
The \browser\_patches/firefox/juggler/content\ directory now contains the core content-process agents (\FrameTree\, \PageAgent\, \Runtime\, \WorkerMain\, and \JugglerFrameChild\) that enable Playwright's Juggler protocol to control Firefox. These files implement the logic for tracking frame trees, managing isolated JavaScript execution contexts, handling worker runtime events, and bridging browser-side commands (such as input dispatching, script evaluation, and navigation interception) to the content process.
_browser\patches/firefox/juggler/content · high confidence
Introduce Juggler protocol implementation for Firefox
The Juggler protocol implementation for Firefox is now available in the \browser\_patches/firefox/juggler/protocol\ directory, providing the core infrastructure for browser automation. This change adds the \BrowserHandler\, \PageHandler\, and \Dispatcher\ classes to manage sessions, targets, and protocol messages, along with \Protocol.js\ and \PrimitiveTypes.js\ to define the API schema and validate parameters. This establishes the foundation for controlling Firefox via the Juggler protocol, enabling features like page management, network interception, and screencasting.
_browser\patches/firefox/juggler/protocol · high confidence
Introduce MCP server utilities with configurable heartbeat and HTTP transport
New files in packages/playwright-core/src/tools/utils/mcp establish the core infrastructure for the Model Context Protocol (MCP) integration. The http.ts module provides an HTTP server implementation supporting both SSE and Streamable HTTP transports, including session management and host validation. The server.ts module defines the MCP server logic, introducing a configurable heartbeat ping timeout via the PLAYWRIGHT\_MCP\_PING\_TIMEOUT\_MS environment variable (defaulting to 5000ms) and handling tool registration and execution. The tool.ts module provides utilities for defining tool schemas using Zod and converting them to MCP tool definitions.
packages/playwright-core/src/tools/utils/mcp · high confidence
Introduce Playwright Chrome Extension for browser-based AI automation
The packages/extension directory now contains the source code and configuration for the Playwright Chrome Extension, enabling AI agents to connect to and interact with pages in an existing browser session using the user's current cookies and login state. This entry provides the extension's manifest (version 0.4.0, Manifest V3), TypeScript build configurations (targeting TypeScript 6.0), and Vite build setup for the service worker and UI pages. It supports multiple simultaneous client connections, each managing its own tab group, and allows users to bypass connection approval dialogs via a unique authentication token or select specific Chrome profiles using the --profile-dir-name option.
packages/extension · high confidence
Introduce Playwright MCP server with extension-based browser automation
The \packages/playwright-core/src/tools/mcp\ directory now contains the core implementation for the Playwright Model Context Protocol (MCP) server. This adds a new capability to connect to browsers via a Chrome Extension using a new CDP relay protocol (v2), supporting features like isolated browser contexts, remote CDP endpoints, and configurable idle timeouts. The implementation includes a new \BrowserModel\ for tab management, a \CDPRelayServer\ for WebSocket bridging, and configuration resolution for CLI and MCP modes, enabling LLMs to control browsers through standard MCP tool interfaces.
packages/playwright-core/src/tools/mcp · high confidence
Introduce WebKit browser launcher and configuration scripts
Added \pw\_run.sh\, \UPSTREAM\_CONFIG.sh\, and \.gitignore\ to the WebKit browser patches. The \pw\_run.sh\ script provides a unified entry point to launch the Playwright or MiniBrowser binaries on macOS and Linux, automatically handling platform-specific environment variables (such as \DYLD\_LIBRARY\_PATH\ on macOS and \LD\_LIBRARY\_PATH\/\WEBKIT\_INJECTED\_BUNDLE\_PATH\ on Linux) and locating the correct build artifacts. The \UPSTREAM\_CONFIG.sh\ file defines the remote repository URL, base branch, and specific revision for the WebKit source code, while \.gitignore\ excludes the local checkout directory.
_browser\patches/webkit · high confidence
Introduce WebView backend for WebKit automation
Adds a new \webview\ backend for WebKit that connects to the browser via the WebKit DevTools Protocol (CDP) instead of the legacy internal protocol. This change introduces a new set of server-side components (\WVBrowser\, \WVPage\, \WVConnection\, etc.) that handle page lifecycle, input simulation (keyboard, mouse, touch), network interception, and execution context management through a dedicated \SyncServer\ for cross-origin dialog handling. It also includes the necessary protocol type definitions and transport logic to support this new connection mode.
packages/playwright-core/src/server/webkit/webview · high confidence
Introduce \`@playwright/test\` package with CLI and reporter exports
A new \@playwright/test\ package is introduced, providing a dedicated CLI entry point (\cli.js\) that delegates to the main Playwright program, and explicit module exports for the test runner API (\index.js\, \index.mjs\, \index.d.ts\) and the reporter API (\reporter.js\, \reporter.mjs\, \reporter.d.ts\). This structure allows users to import test and reporter types directly from \@playwright/test\ subpaths, separating the test runner interface from the core browser automation library.
packages/playwright-test · high confidence
Introduce automated linting for documentation code snippets
Added a new CLI tool in utils/doclint/linting-code-snippets that automatically validates code examples found in the project's Markdown documentation. The tool extracts code blocks and runs language-specific checks: JavaScript and TypeScript snippets are linted using ESLint with configured rules, C\# snippets are checked for syntax errors via Roslyn, Java snippets are validated for syntax using JavaParser (targeting Java 17), and Python snippets are verified for formatting compliance using Black. This ensures that code examples in the docs remain syntactically correct and consistently formatted.
utils/doclint/linting-code-snippets · high confidence
Introduce compressed flakiness dashboard processing
The flakiness dashboard processing pipeline now generates a compressed, optimized view of test results in addition to the raw data. A new Azure Function processes incoming test reports by first storing the raw JSON in the 'raw' blob container, then aggregating and compressing the data into a 'compressed\_v1' format. This compressed format reduces storage size and improves UI performance by stripping unnecessary metadata (such as CI-specific keys and default values), flattening spec structures, and grouping test outcomes by file, title, and parameters. The processing logic handles empty metadata, sharded tests, and platform attribution to ensure accurate flakiness tracking.
utils/flakiness-dashboard/processing · high confidence
Introduce dedicated Playwright configuration for web package component tests
The web package now includes a dedicated Playwright configuration file (playwright.config.ts) to manage its component tests. This configuration sets up a web server using Vite to serve the Playwright gallery at localhost:3102, defines test execution parameters such as retries and output directories, and configures reporters to generate HTML reports on failure and blob reports in CI environments. This change centralizes the test infrastructure for the web package, ensuring consistent test execution and reporting.
packages/web · high confidence
Introduce doclint tooling for API documentation validation and generation
This change adds the \utils/doclint\ directory, introducing a new tooling suite for managing and validating Playwright's API documentation. The \cli.js\ entry point now updates browser versions in \README.md\ and \browsers.json\, refreshes device descriptor user-agents, and validates internal links and code snippet languages across the documentation site. The \api\_parser.js\ and \documentation.js\ modules provide a new Markdown-based API parser and documentation model, enabling language-specific filtering and link rendering. Additionally, \generateDotnetApi.js\ and \dotnetXmlDocumentation.js\ implement a new C\# API generator that produces interfaces, options, and enums from the Markdown specs, while \generateApiJson.js\ serializes the parsed documentation into \api.json\.
utils/doclint · high confidence
Introduce isomorphic test server and tele-reporting infrastructure
This change adds a new set of isomorphic TypeScript modules in \packages/playwright/src/isomorphic\ that form the foundation for the test server and tele-reporting architecture. It introduces \TestServerConnection\ and \TestServerInterface\ to manage the protocol between the test runner and external clients (such as the VS Code extension), \TeleReporterReceiver\ and \TeleSuiteUpdater\ to process and update the test tree from serialized JSON events, and \TestTree\ to render the hierarchical test structure in the UI. Supporting utilities like \EventEmitter\, \StringInternPool\, and type definitions for \GitCommitInfo\ and \CIInfo\ are also included to handle event dispatching, memory-efficient string handling, and metadata reporting.
packages/playwright/src/isomorphic · high confidence
Introduce modular coreBundle and server launcher implementations
Playwright-core now exposes a structured coreBundle that centralizes exports for the client, server, registry, and tools, enabling cleaner entry points for the CLI daemon, dashboard, and MCP server. The BrowserServerLauncherImpl and AndroidServerLauncherImpl are now implemented in dedicated files, providing explicit server launch capabilities for browsers and Android devices with pre-connected device support. A new bootstrap module enforces a Node.js 20 minimum version requirement and adds optional module load profiling via the PW\_INSTRUMENT\_MODULES environment variable. The server registry now uses chokidar to watch browser descriptor files and supports lazy evaluation of cache directories.
packages/playwright-core/src · high confidence
Introduce new Dashboard tooling and session management infrastructure
The \packages/playwright-core/src/tools/dashboard\ directory now contains the core implementation for the Playwright Dashboard, including the \dashboardApp\ server entry point, \dashboardController\ for handling WebSocket connections and UI interactions, and a \SessionProvider\ abstraction with \IdentitySessionProvider\ (for single-context scenarios) and \RegistrySessionProvider\ (for tracking multiple browser sessions via the server registry). This change establishes the backend wiring, dependency list (\DEPS.list\), and session lifecycle management required for the dashboard feature.
packages/playwright-core/src/tools/dashboard · high confidence
Introduce new web UI foundation with system theme support and ANSI rendering
This change establishes the core \packages/web/src\ library, providing the foundational UI components and utilities for the Playwright web interface. It introduces a new theme system that supports Dark, Light, and System modes, automatically respecting the OS-level color scheme preference. Additionally, it adds a custom \ansi2html\ implementation for rendering terminal output with correct colors and styles, alongside utility functions for linkification, settings management, and React hooks.
packages/web/src · high confidence
Introduce protocol types generator utility
Added a new utility script at \utils/protocol-types-generator/index.js\ that automatically generates TypeScript declaration files (\protocol.d.ts\) for Chromium, Firefox, and WebKit by fetching their respective debugging protocols. This tool ensures that the internal server-side type definitions stay synchronized with the browser engines' APIs, reducing manual maintenance and type errors when browser protocols evolve.
utils/protocol-types-generator · high confidence
Introduce winldd utility for resolving Windows DLL dependencies
Adds the winldd tool (PrintDeps), a Windows utility that resolves and prints the full paths of DLL dependencies for .exe and .dll files, similar to the Linux ldd command. The change includes the C++ source code, Visual Studio project files, and build scripts to compile the tool, which is used internally to verify dependency loading on Windows.
_browser\patches/winldd · high confidence
New @playwright/browser-chromium package for explicit browser installation
A new @playwright/browser-chromium package has been introduced to handle the installation of the Chromium browser and its headless shell. This package contains an install script that triggers the download of Chromium, the headless shell, and FFmpeg dependencies when installed via npm, allowing users to manage browser binaries separately from the core Playwright library.
packages/playwright-browser-chromium · high confidence
New Android emulator and Chromium bisect utility scripts
Added a suite of shell and Node.js scripts in the utils directory to streamline Android testing and browser development workflows. The new avd\_install.sh, avd\_recreate.sh, avd\_start.sh, and avd\_stop.sh scripts automate the setup, configuration, and lifecycle management of an Android Virtual Device (AVD) using the Android SDK command-line tools, including the installation of the Chromium WebView. Additionally, bisect-chromium.mjs provides a tool to bisect Chrome for Testing per-commit builds to identify regressions, and build\_android\_driver.sh automates the Gradle build of the Android driver APKs for CDN upload.
utils · high confidence
New CLI client tooling for browser session management
The \packages/playwright-core/src/tools/cli-client\ directory now contains the core implementation for the Playwright CLI client, introducing a structured approach to managing browser sessions via a daemon. This includes a vendored \minimist\ argument parser, a \channelSessions\ module that detects and lists local Chrome and Edge browser instances for CDP attachment, and a \registry\ system that tracks session state and communicates with the Playwright daemon via Unix sockets. The \program.ts\ entry point wires these components together to support commands like \list\, \open\, \attach\, and \close\, enabling users to interact with browser sessions from the command line.
packages/playwright-core/src/tools/cli-client · high confidence
New CLI commands for inspecting trace files
The Playwright CLI now includes a suite of commands under the 'trace' namespace for inspecting trace files directly from the terminal. Users can open and close trace archives, list and filter actions, network requests, console messages, and errors, and view detailed information for specific items. Additionally, the CLI allows extracting screenshots and attachments, and running Playwright CLI commands against DOM snapshots captured during trace actions.
packages/playwright-core/src/tools/trace · high confidence
New Docker images for Ubuntu 24.04 and 26.04 with Node.js 24
Playwright now provides official Docker images based on Ubuntu 24.04 (Noble) and Ubuntu 26.04 (Resolute Raccoon), in addition to the existing Ubuntu 22.04 (Jammy) image. These new images are built on Node.js 24 and include the zstd compression tool, which is required for compatibility with actions/cache. The build and publishing infrastructure has been updated to support these new flavors, allowing users to pull images tagged with -noble or -resolute suffixes.
utils/docker · high confidence
New ESLint rule enforces progress handling in async calls
Added a new ESLint rule, \await-must-use-progress\, to the \utils/eslint-plugin-progress\ package. This rule checks that any awaited asynchronous call within a function accepting a \Progress\ parameter either passes the \progress\ object as its first argument or is wrapped in a \progress.race()\ call, ensuring proper cancellation and timeout support in server-side code.
utils/eslint-plugin-progress · high confidence
New Playwright DevOps skill for CI failure analysis
Added a new \.claude/skills/playwright-devops\ skill that enables automated analysis of CI failures for the Playwright repository. This includes a \fetch-commit-logs.sh\ script to download failed job logs from GitHub Actions for a specific commit, and a \commit-failures.md\ guide that instructs users on how to generate a CI health report grouping failures by root cause (regressions, flakes, or infrastructure issues).
.claude/skills/playwright-devops · high confidence
New Playwright browser extension with tab-group-based debugging
The extension now uses a dedicated background service worker to manage Playwright debugging sessions via Chrome tab groups. Users connect by selecting a tab in the connect page, which creates a named, color-coded tab group that acts as the single source of truth for which tabs are debugged; dragging tabs in or out of the group automatically attaches or detaches the debugger. The extension supports multiple simultaneous client connections, each with its own group, and keeps the service worker alive while the connect page is open to maintain the relay WebSocket. Internal plumbing has been split into ConnectedTabGroup, PendingConnections, and protocol handlers to manage the handshake, tab lifecycle, and Chrome event forwarding.
packages/extension/src · high confidence
New Playwright test examples for GitHub API and SVGOMG
Added new Playwright test examples for the GitHub API and SVGOMG applications. The GitHub API example demonstrates programmatic API testing by creating and deleting a repository and managing issues, while the SVGOMG example provides end-to-end tests for the SVG optimization tool, covering menu verification, default settings, feature toggles, file uploads, and downloads. Both examples include configuration files using the new defineConfig syntax and are set up to run across multiple browsers (Chromium, Firefox, WebKit) with CI-specific settings like retries and parallel execution disabled.
examples/svgomg · high confidence
New WebAuthn example scripts demonstrating credential registration and seeding
Added two new example scripts in the WebAuthn directory that demonstrate how to use the \context.credentials\ API. The \register-and-login.mjs\ script shows a full user flow of registering a new credential and logging in via the webauthn.io demo site. The \seed-credential.mjs\ script demonstrates how to register a credential in one browser context and then seed that same credential into a fresh context to authenticate automatically without further user interaction.
examples/webauthn · high confidence
New agent skill for Playwright component testing via story gallery
A new agent skill has been added to guide users in setting up component testing using a story gallery pattern, which serves as a replacement for the deprecated \@playwright/experimental-ct-\*\ packages. This skill provides a comprehensive reference implementation for the gallery contract (exposing \window.mount\ and \window.unmount\), along with framework-specific setup guides for React and Vue, and templates for writing stories and tests. It also includes a migration guide to help teams transition from the old component testing runtime to this new approach, which leverages the app's own dev server and the built-in \mount\ fixture.
packages/playwright-core/src/tools/skills/playwright-component-testing · high confidence
New browser reinstall scripts and WSL setup for WebKit
The installation scripts in this package now include dedicated reinstallers for Google Chrome (Stable and Beta) and Microsoft Edge (Stable, Beta, and Dev) across Linux, macOS, and Windows, ensuring reliable updates for these branded browsers. Additionally, a new PowerShell script automates the setup of a WSL distribution for running WebKit on Windows, and a helper script ensures the Server Media Foundation feature is installed on Windows Server environments.
packages/playwright-core/bin · high confidence
New build tooling for WebP codec and build infrastructure
The build system now includes a self-contained WebP codec compiled from libwebp to WebAssembly, providing synchronous encode and decode capabilities for Node.js. This is supported by new build scripts in utils/build (build.js, clean.js, bundle\_report.js) that manage the compilation, bundling, and license generation for the codec and other packages, along with utility scripts for updating canary versions and Dockerfile Node.js versions.
utils/build · high confidence
New centralized exports for MCP, CLI, and dashboard capabilities
The \packages/playwright-core/src/tools\ module now provides a unified entry point that exposes core functionality for the Model Context Protocol (MCP), CLI daemon, and dashboard integration. Users can now import specific utilities such as \openDashboardForContext\ to launch the dashboard for a specific browser context, \installSkills\ to manage agent skills, and various MCP backend components like \BrowserBackend\ and \browserTools\ directly from this single location, simplifying access to these internal tools.
packages/playwright-core/src/tools · high confidence
New extension UI for connection approval and status management
The extension now includes a dedicated user interface for managing browser connections. Users will see a new connect page that displays a security warning, allows them to select specific browser tabs to grant access to, and provides an option to bypass the dialog using a generated authentication token. A status page has also been added to show currently active client connections, list accessible tabs, and allow users to disconnect clients directly from the extension.
packages/extension/src/ui · high confidence
New foundational UI components for the web interface
This change introduces a suite of new React components in the web package to support the UI Mode and Trace Viewer. Key additions include CodeMirrorWrapper for syntax-highlighted code editing with line highlighting, Expandable for accessible collapsible sections, ListView and GridView for data display with keyboard navigation and sorting, SplitView for resizable panes, and ErrorMessage for displaying styled error text. These components form the building blocks for the new interface layouts.
packages/web/src/components · high confidence
New image comparison utilities with perceptual color and SSIM analysis
The \packages/utils/image\_tools\ package now includes a new \compare\ function that evaluates image differences using a combination of CIE94 color delta, variance checks, and Structural Similarity Index (SSIM). This utility distinguishes between significant pixel mismatches (marked red), anti-aliased edges (marked yellow), and identical regions (marked gray), allowing for more accurate visual regression testing that accounts for human perception and rendering artifacts.
_packages/utils/image\tools · high confidence
New injected webview modules for dialog bridging and input synthesis
This change introduces two new injected source files for the webview: \webViewDialog.ts\ and \webViewInput.ts\. The dialog bridge overrides \window.alert\, \confirm\, and \prompt\ to tunnel calls through a synchronous XHR to a host-side DialogBridge HTTP server, enabling dialog handling in environments like WebKit that lack native RDP dialog support. The input module provides synthetic keyboard and mouse event dispatching, including support for cross-origin iframes, shadow roots, and legacy WebKit-specific key identifiers, with events dispatched in separate tasks to mimic real user input behavior.
packages/injected/src/webview · high confidence
New internal test runner infrastructure and error context generation
The \packages/playwright/src\ directory now contains the core implementation files for the test runner, including \index.ts\ (fixtures and API), \program.ts\ (CLI commands like \test\, \clear-cache\, \show-report\, \init-agents\), and \errorContext.ts\ (generating structured error reports with code frames). This change introduces the \globals.ts\ module for managing test state and \DEPS.list\ for dependency tracking, establishing the foundational structure for the \@playwright/test\ package's execution engine and CLI interface.
packages/playwright/src · high confidence
New isomorphic utility package for shared Playwright logic
A new \packages/isomorphic\ library has been introduced to centralize and share code between the Node.js and browser environments. This package provides a comprehensive suite of utilities, including CSS parsing and tokenization, ARIA snapshot generation and rendering, and device descriptors for mobile emulation. It also includes helpers for Istanbul code coverage data handling, base64 encoding, color formatting, and image scaling, alongside core protocol and assertion utilities.
packages/isomorphic · high confidence
New mock examples for Battery Status and File System APIs
Added two new example projects—mock-battery and mock-filesystem—that demonstrate how to use the Battery Status API and the File System Access API (showOpenFilePicker, showDirectoryPicker) with Playwright. Each example includes a demo page, a Playwright configuration, and end-to-end tests that inject mock implementations to verify UI updates and API interactions without requiring real hardware or file-system access.
examples/mock-battery, examples/mock-filesystem · high confidence
New script to generate shared object to package mappings for Linux browsers
Added a new Node.js script and accompanying Docker process script in the linux-browser-dependencies utility that scans installed browser binaries to identify missing shared libraries and maps them to the required system packages. This tool outputs a structured mapping of libraries to packages and lists the specific dependencies required for each browser (Chromium, Firefox, WebKit), aiding in the maintenance of accurate system dependency lists for Linux environments.
_utils/linux-browser-dependencies/inside\docker · high confidence
New shared UI components for dialogs, image diffs, and resizing
The shared web module now includes a reusable Dialog component that handles modal/non-modal display, keyboard dismissal (Escape), and click-outside-to-close behavior with anchor-based positioning. An ImageDiffView component provides a tabbed interface for comparing screenshots (Diff, Actual, Expected, Side by side, and Slider modes) with keyboard-accessible mode switching. A ResizeView component enables draggable horizontal/vertical dividers for resizable layouts, backed by a GlassPane overlay to capture mouse events across the viewport.
packages/web/src/shared · high confidence
New type generation tooling and override definitions
The \utils/generate\_types\ directory now includes the core generator script (\index.js\), a parser for TypeScript override files (\parseOverrides.js\), and new override definition files (\overrides.d.ts\, \overrides-test.d.ts\, \overrides-testReporter.d.ts\) along with an \exported.json\ manifest. This tooling enables the generation of TypeScript definitions by merging source documentation with these manual overrides, ensuring that specific Playwright and Playwright Test APIs (such as reporter options, test fixtures, and core browser interfaces) are correctly typed and exported.
_utils/generate\types · high confidence
New utility library for cross-platform and network operations
The packages/utils directory now contains a comprehensive set of shared utilities. This includes platform detection logic supporting macOS Tahoe (macOS 26) and Ubuntu 26.04, Chromium channel user-data directory mappings, and image comparison tools for PNG, JPEG, and WebP formats. Network capabilities have been added, featuring HTTP request handling with socket timeouts, proxy support, and WebSocket server creation with Host header validation. Additional features include cryptographic helpers for self-signed certificate generation, file path sanitization, and environment variable parsing.
packages/utils · high confidence
New utility modules for browser connection, extension detection, and skill installation
The \packages/playwright-core/src/tools/utils\ directory now includes several new utility modules that support internal tooling and CLI operations. \connect.ts\ provides a function to connect to a browser across different Playwright versions using a descriptor, enabling flexible browser attachment. \extension.ts\ introduces logic to detect whether the Playwright Chrome extension is installed in specific user profiles, handling both unpacked and Web Store installations while ignoring orphaned preference entries. \installSkills.ts\ adds functionality to copy agent skills (such as \playwright-cli\, \playwright-component-testing\, and \playwright-trace\) to either the current working directory or the user's home directory, supporting both local and global installation targets. Additionally, \socketConnection.ts\ offers a TCP socket wrapper for sending and receiving JSON messages, and \DEPS.list\ enforces strict TypeScript mode for these new files.
packages/playwright-core/src/tools/utils · high confidence
Restored component gallery for web tests
The component gallery infrastructure for Playwright web tests has been restored. This includes a new Vite configuration serving the gallery on port 3102, an HTML entry point, and a React-based main module that dynamically loads story files. This setup enables the component tests to mount and unmount specific UI stories for verification.
packages/web/playwright · high confidence
Separate browser packages for Firefox and WebKit
New standalone packages (@playwright/browser-firefox and @playwright/browser-webkit) are introduced to handle browser installation. These packages contain install scripts that automatically download and install the respective browser binaries (Firefox or WebKit) during npm install, allowing users to install specific browser dependencies without pulling in the entire Playwright core package.
packages/playwright-browser-firefox, packages/playwright-browser-webkit · high confidence
Trace viewer server now supports HTTP and configurable host/port
The trace viewer can now be started as an HTTP server, allowing it to be accessed remotely or from other processes. Users can specify the host and port via the new \TraceViewerServerOptions\. The server handles trace data serving, including support for live traces and directory-based trace collections, and integrates with Vite for Hot Module Replacement (HMR) during development. It also preserves query parameters during redirects and supports WebSocket transport for server-side scenarios.
packages/playwright-core/src/server/trace/viewer · high confidence
WebKit patch bootstrap introduces Playwright protocol domains and CDP interception
The bootstrap patch for WebKit adds Playwright-specific CDP domains (Dialog, Emulation, Input, Playwright, Screencast) to the inspector protocol and implements a message interception mechanism in the backend dispatcher, allowing Playwright to intercept and modify CDP messages before they are processed.
_browser\patches/webkit/patches · high confidence
Architecture
Introduce dedicated remote server architecture for Playwright connections
The remote connection layer has been restructured into a dedicated \packages/playwright-core/src/remote\ module, introducing a new \PlaywrightServer\ class that manages WebSocket and pipe-based connections. This change adds specific transport implementations (\WebSocketServerTransport\, \SocketServerTransport\) and a central \PlaywrightConnection\ handler to manage client sessions, pre-launched browser reuse, and debug controller modes. The new architecture supports multiple connection modes (default, launchServer, launchServerShared, extension) and includes a \DEPS.list\ to explicitly define the module's internal dependencies, replacing the previous ad-hoc server logic.
packages/playwright-core/src/remote · high confidence
Introduce folder-based dependency lists for server module resolution
The server module resolution is now governed by explicit dependency lists (DEPS.list) rather than implicit file system traversal. New DEPS.list files in the server root and common directories define which modules, directories, and specific files are included in the server bundle, ensuring that only necessary code is shipped and reducing bundle size.
packages/playwright-core/src/server · high confidence
Playwright CLI restructured into modular components
The Playwright CLI implementation in \packages/playwright-core/src/cli\ has been refactored from a monolithic structure into distinct, modular files. The main entry point (\program.ts\) now explicitly imports and registers commands from specialized modules: \browserActions.ts\ (handling \open\, \codegen\, \screenshot\, \pdf\), \driver.ts\ (handling \run-driver\, \run-server\, \launch-browser-server\), and \installActions.ts\ (handling \install\, \uninstall\, \install-deps\). This change improves code organization and maintainability by separating concerns, while preserving the existing command-line interface and functionality for users.
packages/playwright-core/src/cli · high confidence
Playwright client codebase restructured into a new modular layout
The \packages/playwright-core/src/client\ directory has been reorganized to support a new dependency and build system. A new \DEPS.list\ file explicitly defines the client's internal dependencies, including \@isomorphic\ modules, \@protocol\ types, and specific utility files. The client source files (such as \android.ts\, \artifact.ts\, \browser.ts\, \browserContext.ts\, and \browserType.ts\) have been moved into this new structure, importing from these internal aliases and local relative paths rather than the previous flat layout.
packages/playwright-core/src/client · high confidence
Protocol runtime moved to packages/protocol with generated shared types and serializers
The protocol runtime has been relocated into the \packages/protocol\ directory, introducing a new set of generated files that define the shared interface between client and server. This includes \structs.d.ts\ for TypeScript type definitions, \validator.ts\ and \validatorPrimitives.ts\ for runtime argument validation, and \serializers.ts\ for handling serialization of complex values like Maps, Sets, and errors. This change centralizes the protocol schema and serialization logic, ensuring that both client and server channels share a consistent, generated contract for method parameters, results, and events.
packages/protocol/src · high confidence
Recorder backend refactored into modular components
The recorder backend in \packages/playwright-core/src/server/recorder\ has been restructured into distinct modules to improve maintainability and separation of concerns. The \recorderApp.ts\ file now handles the application lifecycle, including launching the in-page overlay and managing the dispatcher interface, while \recorderSignalProcessor.ts\ centralizes the logic for buffering and merging actions (such as handling double-clicks or duplicate navigations). New utility files like \recorderUtils.ts\ and \throttledFile.ts\ provide shared helpers for selector generation and file output, and \chat.ts\ introduces a WebSocket-based chat interface for the recorder. This change organizes the previously monolithic recorder logic into a cleaner, file-based structure without altering the external API.
packages/playwright-core/src/server/recorder · high confidence
Recorder logic moved to injected script with polling architecture
The recorder's core logic has been relocated into the injected script package, introducing a new PollingRecorder that synchronizes state with the main UI via a 1-second polling interval rather than direct synchronous calls. This change includes the addition of SVG icon assets and a generated clip-paths module to support the recorder's visual overlay, while enforcing a strict dependency policy where the injected recorder must access external modules through the injected script's utility layer to prevent global duplication.
packages/injected/src/recorder · high confidence
Restructure injected scripts into a dedicated package with strict dependency isolation
The helper sources previously scattered across the codebase are now consolidated into the \packages/injected/src\ directory. This new structure enforces strict dependency isolation: files in this folder are bundled into the browser environment and are restricted to depending only on isomorphic modules (as defined by the new \DEPS.list\), ensuring they remain free of Node.js or server-side dependencies. This change reorganizes the internal architecture of the injected scripts without altering their external behavior.
packages/injected/src · high confidence
Server dispatcher layer restructured into dedicated modules
The server-side dispatcher implementation in \packages/playwright-core/src/server/dispatchers\ has been reorganized from a monolithic structure into distinct, single-responsibility modules (e.g., \androidDispatcher.ts\, \browserContextDispatcher.ts\, \debuggerDispatcher.ts\). This change introduces a \DEPS.list\ file to explicitly manage module dependencies and enforces a strict dispatcher API convention for server types, improving code maintainability and clarity for the internal protocol handling layer.
packages/playwright-core/src/server/dispatchers · high confidence
Test runner architecture refactored into a bundled, modular structure
The test runner implementation in \packages/playwright/src/runner\ has been reorganized into a modular, bundled architecture. This change introduces explicit dependency management via \DEPS.list\ files, separates the test loader into its own process (\loaderProcessEntry.ts\) to isolate compilation, and extracts core execution logic into dedicated components like \Dispatcher\ and \FSWatcher\. The public API is now cleanly exposed through \index.ts\, re-exporting the test runner, test server, watch mode, and reporters as distinct modules, while internal files use direct relative imports for better maintainability.
packages/playwright/src/runner · high confidence
Test runner core modules consolidated into a single common package
The internal test runner architecture has been reorganized by consolidating core modules—such as configuration loading, fixture management, test suite handling, and inter-process communication—into a new \packages/playwright/src/common\ directory. This change introduces a \DEPS.list\ file to explicitly manage module dependencies and exports a unified \index.ts\ barrel file, streamlining how the test runner loads and wires these components together.
packages/playwright/src/common · high confidence
Trace Viewer UI components extracted to a shared location
The Trace Viewer UI components have been extracted into the \packages/trace-viewer/src/ui\ directory, establishing a shared location for the viewer's interface logic. This change introduces a \DEPS.list\ file to manage internal dependencies and adds new CSS and TypeScript files for core UI elements, including the action list, annotations tab, ARIA mode view, attachments tab, browser frame, and call tab. This restructuring supports the reuse of these UI components across different contexts, such as the HTML reporter and UI mode.
packages/trace-viewer/src/ui · high confidence
Worker execution logic restructured into dedicated modules
The test worker's execution logic has been reorganized into separate, dedicated files: \fixtureRunner.ts\ now handles fixture setup and teardown, \testInfo.ts\ manages test metadata and step tracking, \testTracing.ts\ controls trace recording, \timeoutManager.ts\ handles timeout enforcement, and \workerMain.ts\ orchestrates the worker lifecycle. This change improves code maintainability and separation of concerns within the test runner's worker process.
packages/playwright/src/worker · high confidence
Behavioural changes
Android server implementation refactored into modular components
The Android server logic in \packages/playwright-core/src/server/android\ has been restructured to improve maintainability and separation of concerns. The \android.ts\ file now contains the core \Android\ and \AndroidDevice\ classes, handling device lifecycle, WebView polling, and driver installation, while \backendAdb.ts\ isolates the ADB protocol communication and socket handling. A new \DEPS.list\ file explicitly defines the dependency graph for this module, ensuring strict import boundaries. This change also introduces the \omitDriverInstall\ option, allowing users to skip driver APK installation if it is already present on the device.
packages/playwright-core/src/server/android · high confidence
Automated browser patch synchronization script
A new shell script, \roll\_from\_upstream.sh\, has been added to the \browser\_patches\ directory to automate the synchronization of browser patches from the upstream \playwright-browsers\ repository. This tool allows developers to update Firefox, WebKit, and Windows LDD patches by running \rsync\ against a specified source checkout, supporting optional filters for specific browser engines to streamline the maintenance of browser-specific modifications.
_browser\patches · high confidence
Browser downloads now run in a separate process with improved progress reporting and reliability
The browser installation process has been refactored to execute downloads in an out-of-process worker (oopDownloadBrowserMain), which prevents the main CLI from hanging if the download connection closes unexpectedly. This change introduces a visual progress bar during installation, displays the source URL for each download, and uses unique temporary directories to prevent concurrent downloads from interfering with each other. Additionally, the system now validates system dependencies on Linux and Windows before attempting installation and provides clearer error messages for missing libraries.
packages/playwright-core/src/server/registry · high confidence
Configure Firefox preferences for Playwright automation
The Firefox browser patch now includes a dedicated preferences file (00-playwright-prefs.js and playwright.cfg) that configures the browser for automated testing. This configuration disables telemetry, updates, and first-run notifications, isolates permissions by user context, disables cross-process iframes and BFCache to ensure reproducible state, and forces PDFs to download. It also disables system color themes and native dialogs to ensure consistent UI behavior during tests.
_browser\patches/firefox/preferences · high confidence
Firefox browser patches updated to support new emulation features and protocol improvements
The Firefox browser patches have been updated to include support for new emulation capabilities such as prefers-contrast overrides and improved touch event propagation in nested browsing contexts. The update also introduces a Juggler pipe installation mechanism for Windows to facilitate debugging connections, adds Juggler and Marionette files to the installer manifest, and modifies the WebSocket server handshake to accept an expected path parameter for more flexible protocol handling.
_browser\patches/firefox/patches · high confidence
HAR recording now supports streaming large files and separate resource storage
The HAR recorder has been refactored to stream the output file field-by-field, allowing it to handle HAR files larger than 512MB without hitting V8 string length limits. It also introduces a \resourcesDir\ option to store network response bodies as separate files instead of embedding them in the main HAR JSON, and supports creating a ZIP archive of the HAR and its resources. Additionally, the recorder now respects the \PLAYWRIGHT\_HAR\_NO\_WEBSOCKET\_FRAMES\ environment variable to optionally omit WebSocket frame data.
packages/playwright-core/src/server/har · high confidence
HTML reporter rebuilds on Vite with stable scrollbars and CSP asset options
The HTML reporter has been migrated to a Vite-based build system, which changes how the report is generated and served. This migration introduces a stable scrollbar gutter to prevent layout shifts in the report UI and adds a new doNotInlineAssets option to support Content Security Policy (CSP) compatible reports by keeping assets external rather than inlined. The build process now uses Vite plugins for bundling and type generation, replacing the previous tooling.
packages/html-reporter · high confidence
Introduce Vite-based build configuration for the Dashboard
The Dashboard package now uses Vite for its build process, defined by a new vite.config.ts that configures React support, path aliases for internal modules, and the output directory. An index.html entry point and a .gitignore file have been added to support this new development and build environment.
packages/dashboard · high confidence
Introduce modular backend tooling for MCP browser automation
The \packages/playwright-core/src/tools/backend\ directory has been restructured into a modular set of TypeScript files, replacing the previous monolithic implementation. This change introduces a \BrowserBackend\ class that manages browser context lifecycle, session logging, and dynamic tool registration, alongside dedicated modules for specific capabilities such as \common.ts\ (core actions like close/resize), \console.ts\ (message retrieval), \cookies.ts\ (storage management), \devtools.ts\ (debugging and annotation), \dialogs.ts\, \emulation.ts\, \evaluate.ts\, \files.ts\ (upload/drop), \find.ts\ (snapshot search), \form.ts\ (bulk filling), and \codegen.ts\ (multi-language script generation). The new architecture relies on \zod\ for input validation and \debug\ for logging, and includes a \DEPS.list\ to explicitly declare internal and external dependencies for this backend layer.
packages/playwright-core/src/tools/backend · high confidence
Introduce structured CLI command schema and daemon architecture
The CLI daemon now uses a centralized, Zod-based schema system to define and validate commands, replacing the previous ad-hoc argument parsing. This change introduces a formal \CommandSchema\ type in \command.ts\ that enforces strict validation for arguments and options, automatically generating help text and JSON metadata via \helpGenerator.ts\. The \commands.ts\ file now explicitly declares all CLI actions (such as \open\, \attach\, \goto\, and \press\) with their specific categories and parameters, ensuring consistent behavior and error reporting across the Playwright CLI interface.
packages/playwright-core/src/tools/cli-daemon · high confidence
Isomorphic trace package restructured with hardened snapshot rendering
The \packages/isomorphic/trace\ package has been reorganized into a modular structure, introducing dedicated files for trace loading (\traceLoader.ts\), model management (\traceModel.ts\), and modernization (\traceModernizer.ts\), alongside new entry and version type definitions. This update introduces a hardened snapshot renderer (\snapshotRenderer.ts\) that actively neutralizes XSS vectors in crafted trace files by stripping event handlers, rejecting unsafe tag names, and blocking dangerous attributes on frames and objects. Additionally, the trace server (\snapshotServer.ts\) now enforces a strict Content Security Policy with script nonces, and the trace model now supports test annotations and attributes network requests to service workers and API request contexts.
packages/isomorphic/trace · high confidence
Migrate recorder build system to Vite
The Playwright Recorder application has been migrated from its previous build setup to Vite. This change introduces a new Vite configuration (vite.config.ts) and an updated entry point (index.html) that loads the React application via an ES module. For users, this modernizes the underlying tooling for the Recorder, which may affect local development workflows and build outputs, while maintaining the same functional interface for recording tests.
packages/recorder · high confidence
New snapshotter implementation for trace recording
The trace recorder now uses a dedicated Snapshotter class to capture DOM snapshots. This introduces a new injected script (snapshotterInjected.ts) that intercepts DOM mutations and CSS changes to produce consistent snapshots, and a server-side Snapshotter class that coordinates snapshot capture across frames. The Tracing class now instantiates this Snapshotter and integrates it into the trace recording flow, enabling more reliable snapshot data in trace files.
packages/playwright-core/src/server/trace/recorder · high confidence
Playwright Chromium package structure and CLI integration
The playwright-chromium package now provides a dedicated CLI entry point (cli.js) that integrates with the core bundle's program decorator, allowing users to run browser-specific commands directly. The package exports the full Playwright API via CommonJS (index.js), ESM (index.mjs), and TypeScript definitions (index.d.ts), all re-exporting from playwright-core. Additionally, the install script has been updated to conditionally install Chromium, Chromium headless shell, and FFmpeg browsers during npm install, unless running in an npx global context.
packages/playwright-chromium · high confidence
Playwright Core package structure and browser version updates
The playwright-core package now includes explicit entry points (index.js, index.mjs, cli.js) and a .npmignore file to control published contents, ensuring the package is correctly structured for consumers. Additionally, the bundled browser versions have been updated: Chromium to revision 1247 (Chrome for Testing 155.0.8059.12), Firefox to revision 1551 (156.0), and WebKit to revision 2367 (26.6).
packages/playwright-core · high confidence
Recorder UI migrated to React 18 and Vite
The Recorder application has been rebuilt using React 18 and Vite, replacing the previous setup. This migration introduces the new React 18 rendering API (ReactDOM.createRoot) and updates the internal component structure to use hooks like useRef, which resolves previous race conditions and improves stability. The UI now features a dedicated Call Log view for tracking recording actions, supports new assertion modes (visibility, value, snapshot), and includes a settings dialog for theme and auto-expect configuration.
packages/recorder/src · high confidence
Refactor CLI entry points and introduce --shuffle option
The CLI implementation in packages/playwright/src/cli has been restructured, moving test execution logic into new testActions.ts and report handling into reportActions.ts, while establishing a DEPS.list for dependency management. This change introduces the --shuffle command-line flag, allowing users to run tests in a random order to better detect flaky tests, and exposes the runner's process.argv via FullConfig.argv for debugging purposes.
packages/playwright/src/cli · high confidence
Regenerated TypeScript type definitions for Playwright Core
The TypeScript declaration files in packages/playwright-core/types have been regenerated, introducing new files protocol.d.ts and structs.d.ts alongside an updated types.d.ts. This update aligns the public API surface with the latest browser protocol changes and internal structural types, ensuring that TypeScript users receive accurate type checking and IntelliSense for the current Playwright version.
packages/playwright-core/types · high confidence
Reporters rewritten to use a unified Screen abstraction and explicit dependency management
The reporter implementations in \packages/playwright/src/reporters\ have been refactored to use a new \Screen\ abstraction (defined in \base.ts\) for all terminal output, replacing direct \process.stdout\/\process.stderr\ access. This change introduces \PLAYWRIGHT\_FORCE\_TTY\ environment variable support to explicitly control TTY detection and dimensions, and ensures ANSI color stripping is handled consistently via \StripAnsiStream\ when colors are disabled. Additionally, a new \DEPS.list\ file has been added to explicitly declare internal and external dependencies for each reporter module, improving build isolation and dependency tracking.
packages/playwright/src/reporters · high confidence
Restructure package entry points to re-export playwright-core and test runner
The \packages/playwright\ package now exposes its API through new entry-point files (\index.js\, \index.mjs\, \test.js\, \test.mjs\, etc.) that re-export functionality from \playwright-core\ and the internal test runner. Specifically, the main entry points now delegate to \playwright-core\, while the \test\ entry points combine the test runner with browser exports, and new \jsx-runtime\ files support component testing. This change also adds a \.npmignore\ to exclude source files from the published package and includes a \ThirdPartyNotices.txt\ for bundled dependencies.
packages/playwright · high confidence
Standalone Firefox and WebKit packages now delegate to playwright-core
The \playwright-firefox\ and \playwright-webkit\ packages have been restructured to act as thin wrappers around \playwright-core\. Their main entry points (\index.js\, \index.mjs\, and \index.d.ts\) now re-export everything from \playwright-core\ rather than containing browser-specific logic, and they include dedicated \install.js\ scripts that trigger the download of only the Firefox or WebKit browser binaries respectively. A CLI entry point (\cli.js\) is also provided in each package to allow running Playwright commands directly from the standalone package.
packages/playwright-firefox, packages/playwright-webkit · high confidence
Trace Viewer build system migrated to Vite with multi-environment support
The Trace Viewer build process has been migrated from Webpack to Vite, introducing a new \vite.config.ts\ that defines separate \client\ and \sw\ (service worker) environments. This change consolidates the build of the main viewer (\index.html\), the UI mode interface (\uiMode.html\), and the snapshot viewer (\snapshot.html\) into a single output directory (\playwright-core/lib/vite/traceViewer\). The configuration includes a custom \bundle\ plugin to handle script injection, alias resolution for internal packages (e.g., \@injected\, \@isomorphic\), and optional Istanbul instrumentation for coverage testing.
packages/trace-viewer · high confidence
Trace Viewer entry points and dependency configuration restructured
The Trace Viewer's build and runtime structure has been updated to support Vite and folder-based dependency management. New entry-point files (index.tsx, uiMode.tsx, snapshotMain.ts, sw-main.ts) have been added to initialize the main viewer, the UI mode, snapshot popouts, and the service worker respectively. A new DEPS.list file defines module dependencies for these entry points, and a vite-env.d.ts file declares the \_\_APP\VERSION\\_ global, enabling the viewer to display its version number on the home screen.
packages/trace-viewer/src · high confidence
Trace viewer service worker refactored with Istanbul coverage and new loader backends
The service worker in the trace viewer has been restructured to support Istanbul code coverage instrumentation via the \@isomorphic/istanbulCoverage\ module and to load traces using dedicated \FetchTraceLoaderBackend\ and \ZipTraceLoaderBackend\ classes. This change introduces a new \DEPS.list\ for dependency management, adds a \progress.ts\ utility for handling load progress splitting, and updates \main.ts\ to integrate these components, enabling the viewer to serve coverage data and handle trace loading (including ZIP archives and live traces) more robustly.
packages/trace-viewer/src/sw · high confidence
Updated TypeScript type definitions for Playwright Test
The TypeScript declaration files for \@playwright/test\ have been regenerated to reflect the latest API surface. This update includes new configuration options such as \doNotInlineAssets\ for the HTML reporter, \printWorkerIndex\ for the list reporter, and \includeRetries\ for the JUnit reporter. It also introduces new test capabilities like \test.abort()\, \test.skip()\ modifiers, and \test.fail.only\, alongside updated types for reporter hooks (e.g., \onEnd\ returning status overrides) and assertion matchers.
packages/playwright/types · high confidence
Updated TypeScript type definitions for Playwright client
The generated TypeScript type definitions in \packages/playwright-client/types/types.d.ts\ have been updated to reflect the latest API surface. This includes new options for \page.evaluate\ such as \serialize\ for Map/Set support and \world\ for context selection, as well as various other interface adjustments across Page, BrowserContext, and other classes. Users relying on strict TypeScript checking will see these new signatures and options available in their IDEs and compilers.
packages/playwright-client/types · high confidence
Updated WebDriver BiDi protocol definitions and Firefox test configuration
The WebDriver BiDi protocol definitions in the third-party directory have been updated to include new emulation capabilities (geolocation, screen settings, screen orientation, locale, timezone, network conditions, and user agent overrides), network controls (extra headers), and permissions management. Additionally, the Firefox launch configuration now includes specific preferences tailored for testing, such as disabling telemetry, safe browsing, and background tab throttling to ensure stable test execution.
_packages/playwright-core/src/server/bidi/third\party · high confidence
Vendored third-party utilities for zip extraction, file locking, and image diffing
The \packages/utils/third\_party\ directory now contains vendored copies of three external libraries: \extract-zip\ (for extracting ZIP archives with symlink and permission handling), \lockfile\ (for managing file-based concurrency locks with stale-lock detection), and \pixelmatch\ (for comparing image pixel data and generating diff masks). These files replace previous vendoring structures, providing the core implementation logic for these utilities directly within the repository.
_packages/utils/third\party · high confidence
Web server and git info logic moved to plugins
The web server management and git commit info collection are now implemented as test runner plugins (webServerPlugin and gitCommitInfoPlugin). This change introduces a plugin-based architecture for these features, allowing for better extensibility and separation of concerns. Users can now leverage the plugin system to customize or extend web server and git info behaviors.
packages/playwright/src/plugins · high confidence
WebKit server implementation restructured and updated to version 26.6
The WebKit browser server implementation has been reorganized into a new modular structure within \packages/playwright-core/src/server/webkit\, introducing dedicated files for connection handling (\wkConnection.ts\), browser management (\wkBrowser.ts\), page lifecycle (\wkPage.ts\), input emulation (\wkInput.ts\), and network interception (\wkInterceptableRequest.ts\). This refactoring aligns the internal architecture with other browser implementations while updating the bundled WebKit engine version to 26.6. Users benefit from improved stability, better separation of concerns in the server code, and access to the latest WebKit features and bug fixes included in the 26.6 release.
packages/playwright-core/src/server/webkit · high confidence
Fixes
Electron app page closing now uses main process to prevent hangs
When closing pages in an Electron application, Playwright now executes the close command from the Electron main process via \webContents.close()\ instead of the default DevTools \Target.closeTarget\. This change prevents the \Target.closeTarget\ operation from hanging when it races with a committing navigation, providing a more stable page lifecycle for Electron tests.
packages/playwright-core/src/server/electron · high confidence
Rewritten TypeScript transformation and ESM loader infrastructure
The transformation layer in packages/playwright/src/transform has been completely rewritten to improve reliability and compatibility. The new architecture introduces a dedicated compilation cache (compilationCache.ts) that persists transformed code and source maps to disk with integrity checks, while a new Babel bundle (babelBundle.ts) handles TypeScript stripping, decorator support, and explicit resource management lowering (skipped on Node 24+). The ESM loading mechanism is now split into an async loader (esmLoader.ts) and a synchronous loader (esmLoaderSync.ts) to better handle Node.js version differences and prevent deadlocks. Additionally, a custom tsconfig-loader (tsconfig-loader.ts) replaces external dependencies to resolve tsconfig paths, extends, and references more robustly, and a new port transport (portTransport.ts) manages communication between the loader and the main process.
packages/playwright/src/transform · high confidence
Test coverage
Add WebKit WebView test infrastructure and fixtures; Add comprehensive test coverage for Chromium-specific features; Add test server configuration and certificates; Added BiDi test infrastructure with CSV reporting and expectation management; Added Electron test suite and fixtures; Added HTML reporter story gallery and type generation for component testing; Added Playwright end-to-end tests for TodoMVC example; Added Playwright extension integration tests; Added React test fixtures for versions 15 through 18; Added Service Worker test assets; Added WPT accessibility name and description tests; Added client certificate test assets and generation script; Added comprehensive test coverage for MCP CLI and dashboard features; Added installation fixture scripts for testing Playwright packages; Added installation tests for the plugin API; Added screenshot test assets for canvas, controls, WebGL, and transforms; Added stress test assets for React application performance testing; Added stress tests for browser and context cycling; Added test assets for CSS, JS, and Worker coverage scenarios; Added test assets for Manifest V3 Chrome extensions; Added test assets for SharedWorker communication; Added test assets for UI, media, and HAR scenarios; Added test assets for back-forward cache and static content scenarios; Added test assets for form evaluation scenarios; Added test assets for frame scenarios; Added test assets for input handling scenarios; Added test assets for load event behavior; Added test assets for multi-value RDN certificates; Added test assets for network tab functionality; Added test assets for web server scenarios; Added test assets for webfont rendering; Added test coverage for the Playwright MCP test server backend; Added test fixtures for accessible text and implicit role calculations; Added test suite for image comparison utilities; Added tests for EventEmitter behavior; Added tests for Firefox user preferences and custom policies; Added to-do notifications test assets; Added type-generation tests for Playwright API; Added unit tests for Android webviews, clock, codegen, JSON schema, sequence, and timeout runner; Expanded test coverage in Playwright test runner; Expanded test coverage in library tests; Extensive test suite updates and maintenance in tests/page; Initial Android test suite and test configuration; Inspector CLI codegen tests restructured into modular files; New installation integration tests; New test infrastructure and reporting tools in tests/config; Updated Modernizr test expectations for Mobile Safari 26; Vendored proxy library for testing.
Dependencies
Initial monorepo structure and dependency setup
The repository is initialized as a monorepo with a root \package.json\ defining the \playwright-internal\ workspace and a minimum Node.js engine requirement of 20. The root \package-lock.json\ (lockfileVersion 3) establishes the baseline for the entire project, pinning development dependencies such as Vite 8.1.0, TypeScript 6.0.3, ESLint 9.39.4, and the Babel suite 7.29.7. Additionally, example projects for GitHub API, mock battery, mock filesystem, SVGOMG, and TodoMVC are added with their own \package.json\ files, introducing \@playwright/test\ and auxiliary tools like \http-server\ and \dotenv\ to the project surface.
(dependencies) · high confidence
Playwright expect library is vendored and bundled
The \@playwright/test\ runner now includes a self-contained copy of the \expect\ assertion library (based on Jest v30.2.0) within \packages/playwright/src/matchers\. This change removes the external dependency on the \expect\ package, replacing it with a bundled implementation (\expectLibrary.ts\) that imports only specific utilities from \@jest/expect-utils\ and \jest-matcher-utils\. The diff also introduces a \DEPS.list\ file to explicitly track these internal dependencies, ensuring the matcher logic is fully integrated into the test runner without requiring the full Jest \expect\ package at runtime.
packages/playwright/src/matchers · high confidence
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
Score
- CAI 38 → 51 (+12.3)
- Rubric changed (rubric-2026.08.15 → rubric-2026.09.16) — scores are not directly comparable.
Lenses
- Code Health 69 → 71 (+1.4)
- Architecture 41 → 60 (+19.1)
- Maturity 61 → 80 (+18.7)
- Readiness 23 → 54 (+31.0)
- Security 62 → 65 (+3.0)
- Accessibility 41 (new)
- Performance 60 (new)
Resolved (127)
- (anonymous) (cognitive 16) (utils/generate_types/index.js)
- (anonymous) (cognitive 17) (utils/doclint/cli.js)
- (anonymous) (cognitive 20) (browser_patches/firefox/juggler/protocol/PageHandler.js)
- (anonymous) (cognitive 25) (utils/roll_browser.js)
- (anonymous) (cognitive 27) (utils/doclint/documentation.js)
- (anonymous) (cognitive 30) (utils/linux-browser-dependencies/inside_docker/list_dependencies.js)
- (anonymous) (cyclomatic 16) (utils/doclint/documentation.js)
- (anonymous) (cyclomatic 21) (utils/linux-browser-dependencies/inside_docker/list_dependencies.js)
- (anonymous) (cyclomatic 21) (utils/roll_browser.js)
- AwaitExpression (cyclomatic 16) (utils/eslint-plugin-progress/index.js)
- Coverage not measured — test suite did not build
- Dimension evaluation failed
- FileTooLong: content/FrameTree.js (browser_patches/firefox/juggler/content/FrameTree.js)
- FileTooLong: content/Runtime.js (browser_patches/firefox/juggler/content/Runtime.js)
- FileTooLong: utils/markdown.js (utils/markdown.js)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- …and 107 more
New (1983)
- (anonymous) (cognitive 26) (utils/roll_browser.js)
- (anonymous) (cognitive 31) (utils/linux-browser-dependencies/inside_docker/list_dependencies.js)
- (anonymous) (cyclomatic 22) (utils/linux-browser-dependencies/inside_docker/list_dependencies.js)
- (anonymous) (cyclomatic 22) (utils/roll_browser.js)
- (computed) (cognitive 20) (browser_patches/firefox/juggler/protocol/PageHandler.js)
- (computed) (cyclomatic 16) (browser_patches/firefox/juggler/protocol/PageHandler.js)
- APIRequestContext._innerFetch (cognitive 53) (packages/playwright-core/src/client/fetch.ts)
- APIRequestContext._innerFetch (cyclomatic 39) (packages/playwright-core/src/client/fetch.ts)
- APIRequestContext._sendRequest (cognitive 74) (packages/playwright-core/src/server/fetch.ts)
- APIRequestContext._sendRequest (cyclomatic 65) (packages/playwright-core/src/server/fetch.ts)
- APIRequestContext.fetch (cognitive 24) (packages/playwright-core/src/server/fetch.ts)
- APIRequestContext.fetch (cyclomatic 20) (packages/playwright-core/src/server/fetch.ts)
- ApiParser.parseArgument (cognitive 26) (utils/doclint/api_parser.js)
- ApiParser.parseArgument (cyclomatic 17) (utils/doclint/api_parser.js)
- BidiChromium._innerDefaultArgs (cognitive 21) (packages/playwright-core/src/server/bidi/bidiChromium.ts)
- BidiChromium._innerDefaultArgs (cyclomatic 16) (packages/playwright-core/src/server/bidi/bidiChromium.ts)
- BidiConnection._dispatchMessage (cognitive 33) (packages/playwright-core/src/server/bidi/bidiConnection.ts)
- BidiConnection._dispatchMessage (cyclomatic 19) (packages/playwright-core/src/server/bidi/bidiConnection.ts)
- BidiNetworkManager._onBeforeRequestSent (cognitive 32) (packages/playwright-core/src/server/bidi/bidiNetworkManager.ts)
- BidiNetworkManager._onBeforeRequestSent (cyclomatic 19) (packages/playwright-core/src/server/bidi/bidiNetworkManager.ts)
- …and 1963 more
Changes since last survey
- 300 commits — 192 feature/other, 108 fixes
By area
- packages/playwright-core — 123 commits
- docs/src — 39 commits
- packages/playwright — 19 commits
- packages/isomorphic — 14 commits
- .github/workflows — 12 commits
- tests/library — 12 commits
- tests/page — 12 commits
- browser_patches/firefox — 9 commits
- packages/trace-viewer — 9 commits
- tests/playwright-test — 8 commits
- (root) — 6 commits
- packages/html-reporter — 6 commits
- tests/mcp — 6 commits
- packages/injected — 5 commits
- packages/utils — 3 commits
- tests/config — 3 commits
- .claude/skills — 2 commits
- packages/extension — 2 commits
- packages/web — 2 commits
- .azure-pipelines/publish.yml — 1 commit
Notable commits
- fix: chore: remove fix flakes bot - it is noise (#42432)
- fix: Revert "docs(cli): cover Python pytest CLI debug in skills and coding-agents guide" (#42412)
- fix: Revert "feat(tracing): allow configuring the screenshots size" (#42411)
- fix: Revert "fix(mcp): drop the backend after browser_close with a shared browser" (#42492)
- fix: devops(bidi): fix publishing when a single csv report is uploaded (#42764)
- fix: fix(agents): add missing parentheses in test-generator example (#42744)
- fix: fix(android): include the from point in the swipe path (#42349)
- fix: fix(android): match webview process by exact pid (#42410)
- fix: fix(aria): annotate aria-hidden elements in AI snapshots (#42268)
- fix: fix(aria): treat searchbox as textbox in embedded control accname (#42433)
- fix: fix(aria-snapshot): quote names that only look like regexes (#42811)
- fix: fix(bidi): don't deserialize the toString property (#42677)
- fix: fix(chromium): allow more screencast frames in flight (#42929)
- fix: fix(chromium): bypass service workers on the storage state page (#42664)
- fix: fix(chromium): disable more background requests to Google services (#42909)
- fix: fix(chromium): dispose worker sessions when their frame session is disposed (#42282)
- fix: fix(chromium): re-apply touch emulation after screenshot beyond viewport (#42617)
- fix: fix(chromium): replay execution contexts when connecting to Android WebView (#42447)
- fix: fix(chromium): report 204 subresource responses as finished (#42834)
- fix: fix(chromium): report numpad location on keyup (#42913)
- …and 280 more
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
microsoft/playwright was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.
About this page
- The score is its most recent published measurement, taken on 28 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit b9a34ac7783a1b6c2e1dfff0c08ac744c048fa59 — the exact code this score is about.
- Scored under rubric-2026.09.16 — the same rubric and the same method as every other entry in this index.
- Measured by watchdog.canine.dev using codehealth-analyzer preprod-eb9197011364.