Deno 2 Playwright Model Context Protocol Server Example

Author:@jakedahn
View on GitHub

Overview

The Deno 2 Playwright MCP Server is a Model Context Protocol server. It enables LLMs to automate web browsers, interact with pages, capture screenshots, and run JavaScript in a real browser via Playwright and Deno 2.

To use it, you must first build the correct binary for your operating system. Then, configure your application to use this executable file.

Its key features include full browser automation with Playwright, the ability to execute JavaScript in a real browser, and support for macOS, Linux, and Windows systems.

Common use cases are automating web application testing, taking programmatic screenshots of web pages, and running code within a headless browser environment.

The server is compatible with Deno 2 and supports macOS, Linux, and Windows. You can customize its settings by editing the configuration file to point to your specific binary. To build for different platforms, use Deno tasks like deno task build-mac or deno task build-linux-x86_64.