Playwright-Lighthouse MCP Server
Runs performance analysis on websites, providing scores for performance, accessibility, best-practices, SEO, and PWA categories, along with specific improvement recommendations
Analyzes Progressive Web App compliance as one of the optional categories in the Lighthouse performance analysis
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Playwright-Lighthouse MCP Server analyze performance of https://example.com with categories performance, seo, and accessibility"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Playwright-Lighthouse MCP Server
A MCP server that analyzes web site performance using Playwright and Lighthouse. Through the Model Context Protocol (MCP), LLMs can perform web site performance analysis.
Features
Performance analysis with Lighthouse
Screenshot capture
Related MCP server: Playwright MCP Server
Setup
Prerequisites
Node.js 18 or higher
npm
Installation
# Clone the repository
git clone https://github.com/kbyk004/playwright-lighthouse-mcp.git
cd playwright-lighthouse-mcp
# Install dependencies
npm install
npx playwright install
# Build
npm run buildUsage
Debugging MCP Server
npm run inspectorIntegration with MCP Clients
This server is designed to be used with clients that support the Model Context Protocol (MCP). For example, it can be integrated with Claude for Desktop.
Configuration Example for Claude for Desktop
Add the following to the Claude for Desktop configuration file (~/Library/Application Support/Claude/claude_desktop_config.json):
{
"mcpServers": {
"playwright-lighthouse": {
"command": "node",
"args": [
"/path-to/playwright-lighthouse-mcp/build/index.js"
]
}
}
}Available Tools
1. run-lighthouse
Runs a Lighthouse performance analysis on the currently open page.
Parameters:
url: The URL of the website you want to analyzecategories: Array of categories to analyze (default: ["performance"])Available categories: "performance", "accessibility", "best-practices", "seo", "pwa"
maxItems: Maximum number of improvement items to display for each category (default: 3, max: 5)
2. take-screenshot
Takes a screenshot of the currently open page.
Parameters:
url: The URL of the website you want to capturefullPage: If true, captures a screenshot of the entire page (default: false)
Output Format
The analysis results include:
Overall scores for each selected category with color indicators
Key improvement areas grouped by category
Path to the saved report file
License
MIT License - see LICENSE for details
Available Tools
2 toolsrun-lighthouseC
Runs a Lighthouse performance analysis on the currently open page
Inputs: url (required), categories, maxItems.
take-screenshotC
Takes a screenshot of the currently open page
Inputs: url (required), fullPage.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 2 tools
The two tools have clearly distinct purposes: one runs a performance analysis (run-lighthouse) and the other captures a visual snapshot (take-screenshot). There is no overlap in functionality, making it easy for an agent to select the correct tool based on the task.
Both tools follow a consistent verb_noun pattern (run-lighthouse, take-screenshot), using hyphenated lowercase names. This predictable naming scheme enhances readability and usability for agents.
With only two tools, the server feels under-scoped for a Playwright-Lighthouse integration, which typically involves more operations like navigation, interaction, or detailed reporting. This limited set may hinder complex workflows that agents might expect from such a domain.
The tool surface is severely incomplete for browser automation and performance testing. Missing are essential operations like opening/closing pages, interacting with elements, running audits with specific configurations, or exporting results, which are core to the domain and could lead to agent failures in broader tasks.
Maintenance
Related MCP Connectors
Free MCP server that audits any public URL: technical SEO, Core Web Vitals, indexing checks.
Website checker for AI coding agents. Measures your site in a real browser, with evidence.
Official Browserless MCP server: browser automation, scraping, screenshots and PDFs for AI agents.
MCP server providing access to the Scorecard API to evaluate and optimize LLM systems.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol server that provides browser automation capabilities using Playwright, enabling LLMs to interact with web pages, take screenshots, and execute JavaScript in a real browser environment.19Apache 2.0
- AlicenseBqualityDmaintenanceA Model Context Protocol server that provides browser automation capabilities using Playwright, enabling LLMs to interact with web pages, take screenshots, generate test code, scrape web content, and execute JavaScript in real browser environments.31MIT
- FlicenseBqualityDmaintenanceA Model Context Protocol server that provides browser automation capabilities using Playwright, enabling LLMs to interact with web pages through structured accessibility snapshots without requiring screenshots or visually-tuned models.24-
- AlicenseAqualityDmaintenanceA Model Context Protocol server that provides browser automation capabilities using Playwright, enabling LLMs to interact with web pages through structured accessibility snapshots without requiring screenshots or visually-tuned models.22Apache 2.0