0Pricing
Frontend Academy · Lesson

Automated Lighthouse Checks

Add the Lighthouse CI GitHub Action, set performance and accessibility score thresholds, and block merges that regress Core Web Vitals.

Why Automate Lighthouse?

Manual Lighthouse runs catch performance regressions late — usually after a real user complains. Automated Lighthouse CI runs on every PR, fails builds that regress key metrics, and trends scores over time. Treat performance like a test suite.

Lighthouse CI

The open-source Lighthouse CI (lhci) toolset by Google: runs Lighthouse multiple times, takes the median, asserts against thresholds, and uploads results.

npm install -D @lhci/cli

# Run locally:
npx lhci autorun

All lessons in this course

  1. GitHub Actions for Frontend: lint test build
  2. Deploying to Vercel Netlify and Cloudflare Pages
  3. Environment Variables in CI
  4. Automated Lighthouse Checks
← Back to Frontend Academy