Puppeteer
@jatidevelopments
Advanced Puppeteer automation server with enhanced functionality (MCP Server)
Overview
What is Puppeteer?
Puppeteer is a Model Context Protocol server that provides browser automation capabilities using Puppeteer. It enables LLMs to interact with web pages, take screenshots, extract and download images, and execute JavaScript in a real browser environment.
How to use Puppeteer?
Configure the server in your MCP client using either Docker (docker run -i --rm --init -e DOCKER_CONTAINER=true mcp/puppeteer) or NPX (npx -y @modelcontextprotocol/server-puppeteer). Optionally set PUPPETEER_LAUNCH_OPTIONS environment variable or pass launchOptions to puppeteer_navigate to customize browser behavior.
Key features of Puppeteer
- Browser automation with navigation, clicking, and form filling
- Screenshot capture of entire pages or specific elements
- JavaScript execution in the browser console
- Image extraction from
<img>tags and CSS backgrounds - Image downloading with automatic filename generation
- Multi-tab browser management and viewport switching
Use cases of Puppeteer
- Automated web scraping and data extraction for LLMs
- Responsive design testing across mobile, tablet, and desktop viewports
- DOM element analysis for understanding page structure and styles
- Visual regression testing via screenshot capture
- Browser history navigation and multi-tab content management
FAQ from Puppeteer
How can I configure Puppeteer server options?
Use either the PUPPETEER_LAUNCH_OPTIONS environment variable with JSON-encoded launch settings, or pass launchOptions and allowDangerous parameters directly to the puppeteer_navigate tool.
What is the difference between Docker and NPX execution?
The Docker implementation uses headless Chromium, while the NPX version opens a visible browser window.
What resources does the server expose?
Console logs at console://logs (browser console output in text format) and screenshots at screenshot://<name> (PNG images of captured screenshots).
What security controls are available?
The allowDangerous parameter (default false) controls whether dangerous Puppeteer launch options like --no-sandbox and --disable-web-security are permitted; setting it to true allows these options.