puppeteer-mcp-server
Overview
puppeteer-mcp-server is a Model Context Protocol server that provides browser automation capabilities using Puppeteer, allowing LLMs to interact with web pages, take screenshots, and execute JavaScript in a real browser environment.
To use puppeteer-mcp-server, build the Docker image and run it using the provided commands: docker build -t puppeteer-mcp-server . docker run --rm -p 8000:8000 puppeteer-mcp-server
- Enables LLMs to interact with web pages seamlessly. - Allows taking screenshots of web pages. - Executes JavaScript in a real browser environment.
- Automating web scraping tasks.
- Testing web applications in a controlled environment.
- Generating visual content from web pages.
Add to your AI client
Use these steps to connect puppeteer-mcp-server in Cursor, Claude, VS Code, and other MCP-compatible apps. The same JSON appears in the Use with menu above for one-click copy.
Cursor
Add this to your .cursor/mcp.json file in your project root, then restart Cursor.
.cursor/mcp.json
{
"mcpServers": {
"puppeteer-mcp-server-anycontext-ai": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-puppeteer-mcp-server-anycontext-ai"
]
}
}
}Claude Desktop
Add this server entry to the mcpServers object in your Claude Desktop config, then restart the app.
~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows)
{
"mcpServers": {
"puppeteer-mcp-server-anycontext-ai": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-puppeteer-mcp-server-anycontext-ai"
]
}
}
}Claude Code
Add this to your project's .mcp.json file. Claude Code will detect it automatically.
.mcp.json (project root)
{
"mcpServers": {
"puppeteer-mcp-server-anycontext-ai": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-puppeteer-mcp-server-anycontext-ai"
]
}
}
}VS Code (Copilot)
Add this to your .vscode/mcp.json file. Requires the GitHub Copilot extension with MCP support enabled.
.vscode/mcp.json
{
"servers": {
"puppeteer-mcp-server-anycontext-ai": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-puppeteer-mcp-server-anycontext-ai"
]
}
}
}Windsurf
Add this to your Windsurf MCP config file, then restart Windsurf.
~/.codeium/windsurf/mcp_config.json
{
"mcpServers": {
"puppeteer-mcp-server-anycontext-ai": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-puppeteer-mcp-server-anycontext-ai"
]
}
}
}Cline
Open Cline settings, navigate to MCP Servers, and add this server configuration.
Cline MCP Settings (via UI)
{
"mcpServers": {
"puppeteer-mcp-server-anycontext-ai": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-puppeteer-mcp-server-anycontext-ai"
]
}
}
}FAQ
What is the primary function of puppeteer-mcp-server?
It provides a server environment for browser automation using Puppeteer, enabling LLMs to perform various web interactions.
How do I run the server?
You can run the server by building the Docker image and executing the run command as specified in the usage section.
Is there any specific environment required to run puppeteer-mcp-server?
It requires Docker to build and run the server.