lighthouse-mcp
Provides tools for running Lighthouse web performance audits, including Core Web Vitals (LCP, CLS, INP), performance scores, and optimization opportunities.
Click on "Install 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., "@lighthouse-mcpAudit https://example.com performance"
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.
Lighthouse MCP Server
通过 MCP 协议在 Claude 中直接运行 Lighthouse 网页性能审计,获取 Core Web Vitals、性能评分和优化建议。
功能
提供两个 MCP 工具:
audit_url — 单页审计
对一个 URL 运行 Lighthouse,返回:
Core Web Vitals: LCP、CLS、INP
其他性能指标: FCP、TTFB、Speed Index、TBT
分类评分: Performance / Accessibility / SEO / Best Practices (0-100)
优化建议: 按预计可节省时间排序的改进机会
audit_batch — 批量审计
对多个 URL(最多 10 个)并行运行 Lighthouse,返回每个页面的核心指标,适合跨页面对比。
Related MCP server: Lighthouse MCP
前置条件
Node.js >= 18
Google Chrome — Lighthouse 依赖 Chrome 运行,
chrome-launcher会自动查找。macOS 上安装 Chrome 即可。
安装
git clone <repo-url>/lighthouse-mcp.git
cd lighthouse-mcp
npm install
npm run build在 Claude Code 中使用
在 ~/.claude/claude_desktop_config.json(或对应配置文件)中添加:
{
"mcpServers": {
"lighthouse": {
"command": "node",
"args": ["/path/to/lighthouse-mcp/build/index.js"]
}
}
}配置后重启 Claude Code,即可使用:
帮我审计一下 https://example.com 的性能
对比这三个页面的性能: https://a.com https://b.com https://c.com
用桌面模式审计 https://example.com输出示例
{
"url": "https://example.com",
"device": "mobile",
"scores": { "performance": 85 },
"coreWebVitals": {
"lcp_ms": 2500,
"cls": 0.1,
"inp_ms": 150
},
"otherMetrics": {
"fcp_ms": 1800,
"ttfb_ms": 200,
"speedIndex_ms": 3000,
"tbt_ms": 200
},
"opportunities": [
{ "title": "Reduce unused JavaScript", "potentialSavingsMs": 500 }
]
}技术栈
@modelcontextprotocol/sdk— MCP 协议实现lighthouse— Google Chrome 网页审计工具chrome-launcher— 无头 Chrome 启动TypeScript + ESM
License
MIT
Available Tools
2 toolsaudit_batchA
Run Lighthouse performance audits on multiple URLs in parallel. Returns a summary comparing Core Web Vitals across all URLs, plus detailed metrics for each.
| Name | Required | Description | Default |
|---|---|---|---|
| urls | Yes | Array of URLs to audit (max 10) | |
| device | No | Device emulation mode (default: mobile) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full transparency burden. It discloses parallel execution and the returned summary/detailed metrics, but does not mention potential side effects, time/resource costs, or concurrency limits beyond what the schema implies.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is two sentences, gets straight to the point, and uses no filler. Every phrase adds value: what the tool runs, the parallel nature, and what it returns.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple tool with two well-documented parameters and no output schema, the description covers the high-level return behavior (summary plus detailed metrics). It does not mention the device parameter default, but that is already in the schema, so this is reasonably complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% and both parameters already have clear descriptions in the schema. The description adds context about Core Web Vitals, but does not enrich parameter meaning further, so the baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb ('Run') and clearly identifies the resource ('Lighthouse performance audits') and scope ('multiple URLs in parallel'). It distinguishes itself from the sibling tool audit_url by emphasizing batch execution and comparative Core Web Vitals results.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The phrase 'multiple URLs in parallel' clearly implies a batch use case and contrasts with a single-URL tool like audit_url. However, it does not explicitly state when not to use this tool or name audit_url as an alternative for single-URL audits.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
audit_urlA
Run a Lighthouse performance audit on a URL. Returns Core Web Vitals (LCP, CLS, INP), other performance metrics (FCP, TTFB, Speed Index, TBT), category scores (0-100), and a prioritized list of improvement opportunities with estimated savings.
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The URL to audit, e.g. https://example.com | |
| device | No | Device emulation mode (default: mobile) | |
| categories | No | Audit categories to run (default: performance only) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. It describes outputs in detail but does not disclose any side effects, prerequisites (e.g., URL accessibility), rate limits, or operational characteristics like execution time. The read-only nature of an audit is implied but not explicit.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single dense sentence that lists concrete return values without repetition or filler. It is front-loaded with the action ('Run a Lighthouse performance audit') and efficiently covers key details.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the absence of an output schema and annotations, the description sufficiently enumerates return values (Core Web Vitals, metrics, category scores, improvement opportunities). It does not cover error cases, limitations, or output format, but for a single-URL audit tool this is largely adequate.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema covers 100% of parameters with descriptions, so the baseline is 3. The description adds no new meaning to the device or categories parameters; it only mentions metrics and scores, which relate to output rather than parameter selection.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states it runs a Lighthouse performance audit on a URL and enumerates the specific metrics returned (Core Web Vitals, performance metrics, category scores, improvement opportunities). It distinguishes itself from the sibling audit_batch by emphasizing a single URL.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The phrase 'on a URL' gives clear context that this tool is for auditing a single URL, implicitly contrasting with audit_batch. However, it does not explicitly mention when to use audit_batch instead or provide exclusions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
2 tool updates
v1.0.0- First observed
audit_batch - First observed
audit_url
TDQS
The two tools are clearly distinct: audit_url handles a single URL while audit_batch handles multiple URLs. There is no overlap or ambiguity in their purposes.
Both tools use the consistent verb_noun pattern (audit_url, audit_batch), making the naming predictable and easy to follow.
With only 2 tools, the server feels thin for a full-featured Lighthouse server, though the tools cover the core audit functionality. It is below the typical 3-15 range.
The tools cover both single and batch audits, returning comprehensive metrics and opportunities. Minor gaps include lack of custom configuration options (e.g., device, categories) or historical comparison, but these are not critical.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Free technical-SEO audit MCP: crawl a site, run checks, return an LLM-ready shareable report.
Rule-based site audits: accessibility, SEO, security headers, performance. Metered per call.
Validate HTML/CSS, audit SEO and JSON-LD, check links, and capture responsive screenshots.
Core Web Vitals metrics by CMS, CDN, and framework — free remote MCP, no auth.
Related MCP Servers
- AlicenseBqualityBmaintenanceMCP server that enables AI agents to perform comprehensive web audits using Google Lighthouse with 13+ tools for performance, accessibility, SEO, and security analysis.111,18667MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI models to perform Google Lighthouse website performance analysis, including Core Web Vitals, accessibility, SEO audits, and actionable optimization recommendations. Provides comprehensive web performance insights through natural language interactions.1,3543MIT
- AlicenseAqualityDmaintenanceCore Web Vitals analysis powered by Lighthouse. Four tools: analyze a URL, compare two URLs, check against thresholds, or crawl an entire site. Works with Claude Code, Cursor, Windsurf, and any MCP-compatible AI tool.420MIT
- FlicenseNot gradedqualityDmaintenanceEnables auditing of websites for performance, SEO, accessibility, security, and mobile readiness, with tools to validate URLs, run page audits, save results, and retrieve reports.1-
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/noGarne/MCP-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server