PageSpeed Insights MCP

Check Core Web Vitals with Lighthouse and real-user Chrome data, for your pages and competitors'

PageSpeed Insights MCP wraps Google's PageSpeed Insights API. It runs Lighthouse on any public URL and pulls real-user Core Web Vitals from the Chrome UX Report. It is a community server by ruslanlap, not Google's, with an Apache-2.0 license. Version 2 has six tools.
Use it two ways. In Claude Code or claude.ai, check your pages after a deploy and compare them with competitors' in one prompt. In your own product, it can power an SEO or website audit feature. It runs only as a local process over stdio, with no hosted URL, so you host it yourself next to your backend.
Page analysis
pagespeedanalyzepage runs Lighthouse and returns scores, findings and recommendations
Real-user vitals
pagespeedget_fielddata returns CrUX Core Web Vitals for a page or a whole origin
Compare pages
pagespeedcomparepages compares two pages, or one page with its saved baseline
Batch and diagnose
pagespeedanalyze_batch triages up to 10 pages; pagespeed_diagnosepage digs into images, JavaScript or third parties
Prompts to try
When to use
  • You want Core Web Vitals checked after every deploy without opening pagespeed.web.dev
  • You need real-user field data, not only a lab score
  • Your product offers website or SEO audits and needs a free performance source
When not to use
  • You need to debug a slow page locally or on localhost: use Chrome DevTools
  • You want a full technical SEO crawl with backlinks and keywords: use Ahrefs or Semrush
  • You need a hosted server with Lighthouse as one of many SEO APIs: use DataForSEO

Watch out

  • The API is free, but Google's default quota is about 25,000 queries a day per Cloud project. In a product, cache results and limit audits per user.
  • Each Lighthouse run takes several seconds and scores vary between runs. Compare several runs before you call a change a regression.
  • It only tests public URLs. Field data shows up only for pages and origins with enough Chrome traffic, so small sites often get none.

Install

Create a Google API key in Google Cloud and enable the PageSpeed Insights API on it. Enable the Chrome UX Report API too if you want field data. Then in Claude Code:
Terminal

Loading editor...

claude mcp add pagespeed -e GOOGLE_API_KEY=your-key -- npx -y pagespeed-insights-mcp
It needs Node.js 20.19 or later. A Docker image builds from the repo.
In your product, there is no hosted URL to attach to the Claude API's mcp_servers. Run it as a local process and connect with an MCP client over stdio, for example Experimental_StdioMCPTransport in the AI SDK, or wrap it in your own HTTP server. Keep the API key on the server.
© 2026 Paralect, Inc 651 N Broad St, Suite 206, Middletown, 19709, Delaware, United States