Lighthouse: what it tests and how to run it

Lighthouse is Google's free audit tool. What it checks, four ways to run it, the settings that change your score, and what a lab test can and cannot tell you.

IntermediateHow-to6 min readUpdated October 30, 2026

In this guide
  1. What Lighthouse is
  2. The four categories
  3. Four ways to run it
  4. Settings that change the result
  5. Useful command line options
  6. What a Lighthouse run cannot tell you
  7. A sensible routine
  8. Check your own page
  9. Sources

What Lighthouse is

Lighthouse is an automated tool for improving the quality of web pages. You give it a web address. It loads the page in Chrome, runs a set of audits, and writes a report on how the page did. Each audit has a reference page explaining why it matters and how to fix it. You can run it against any page, public or behind a login.

It runs on the machine where you start it, and its results are not sent to a remote server. The exception is PageSpeed Insights, where Google runs Lighthouse for you on its side.

The current version at the time of writing is 13.5. Reports show the version in their footer.

The four categories

CategoryWhat it checksHow the score is made
PerformanceHow fast the page loads and becomes usable, with metrics and findingsA weighted average of five metrics. See the performance score
AccessibilityWhether people who use screen readers or the keyboard can use the pageA weighted average of automated checks. Each check is pass or fail, and manual checks are listed but not scored. See the three scores that are not about speed
Best practicesSafety and good practice, such as using HTTPSA weighted average of pass or fail checks. HTTPS, deprecated APIs and third-party cookies count the most
SEOBasics that let search engines find and understand the pageA weighted average of pass or fail checks. A page blocked from indexing counts for about 31%, and structured data is not scored

Most of this series is about the performance category. The others are worth running too. The SEO checks, for instance, include whether the page is blocked from indexing and whether it returns a good status code, which are also what decides whether a page can appear in the Chrome UX Report.

Four ways to run it

1. PageSpeed Insights. Open pagespeed.web.dev, enter an address and press Analyze. Nothing to install, and it adds real-visitor data from the Chrome UX Report above the lab result. See PageSpeed Insights explained. It can only test public addresses.

2. Chrome DevTools. Lighthouse has its own panel. Open the page in Chrome, press Ctrl+Shift+J (Cmd+Option+J on a Mac), choose the Lighthouse tab, set the options and press Analyze page load. A run takes 10 to 60 seconds. The panel can test local sites and pages behind a login. The Chrome team says to use the DevTools workflow instead of the separate extension unless you have a specific reason, because the extension cannot do that.

3. The command line. This gives the most control and is the way to automate. It needs Node 22 or later and a copy of Chrome.

npm install -g lighthouse
lighthouse https://example.com --view

4. Your own code. The Node module returns the report as text and the result as an object, so a script or a build step can read the numbers.

import fs from 'fs';
import lighthouse from 'lighthouse';
import * as chromeLauncher from 'chrome-launcher';

const chrome = await chromeLauncher.launch({chromeFlags: ['--headless']});
const options = {output: 'html', onlyCategories: ['performance'], port: chrome.port};
const result = await lighthouse('https://example.com', options);

fs.writeFileSync('report.html', result.report);
console.log('Performance score', result.lhr.categories.performance.score * 100);
chrome.kill();

To run it on every release and catch regressions, Lighthouse CI wraps the same tool. The Lighthouse documentation also shows how to run it several times and keep the median.

Settings that change the result

Each of these can move your score, so write down the ones you used.

SettingWhat it doesDefault
DeviceMobile sets a mobile user agent and a phone-sized screen. Desktop switches those mobile changes off and judges the page against desktop marksMobile
Throttling methodSimulated loads the page once without throttling and then calculates what a slow connection would have produced. DevTools really slows the network and processor, which takes longer. Provided applies noneSimulated
Clear storageClears the page's saved data before the run, so it measures a first visit. Turn it off to measure a repeat visitOn
ModeNavigation analyses one page load. Timespan covers a stretch of time with interactions. Snapshot looks at the page in its current stateNavigation
CategoriesWhich of the four areas to run. Leaving out the ones you do not need makes the run slightly fasterAll

The simulated mobile test uses a screen 412 by 823 pixels, a network with a 150 millisecond round trip and about 1.6 megabits per second of download, and a processor slowed down four times. The simulated desktop test uses a 1350 by 940 pixel screen, a 40 millisecond round trip, about 10 megabits per second, and no processor slowdown. Lighthouse describes the mobile network as sitting between the slowest 25% of 4G connections and the fastest 25% of 3G connections.

The processor slowdown is relative to the machine you run on. Lighthouse measures the machine's speed and prints it as "CPU/Memory Power" at the bottom of the report. On a weak computer the fixed fourfold slowdown makes pages look slower than they are, and on a strong one, faster. The command line can set a different multiplier with --throttling.cpuSlowdownMultiplier. Use the same machine for tests you want to compare.

Useful command line options

# Desktop, performance only, saved as a JSON file
lighthouse https://example.com --preset=desktop --only-categories=performance --output=json --output-path=./report.json

# Quiet, without opening a window, for scripts
lighthouse https://example.com --quiet --chrome-flags="--headless"

# Several pages from a list, one report each (the reports folder must already exist)
lighthouse --url-file=./urls.txt --output-path=./reports

Other options worth knowing:

To test a site you must log in to, the documentation describes starting a Chrome window with a debugging port, signing in by hand and pointing Lighthouse at that window. To test on a real phone, connect it with USB debugging and turn off the emulation so Lighthouse does not slow a phone that is already slow.

What a Lighthouse run cannot tell you

A sensible routine

  1. Test the pages that matter, not only the home page.
  2. Run both mobile and desktop.
  3. Run each test several times and use the median. Close other programs and use a private window with no extensions, which the Chrome team lists as the first thing to try when a report shows errors.
  4. Save the report. The JSON file can be compared later.
  5. Work from the findings in the report, for the one metric that is weakest. The PageSpeed Insights guide shows how to read them.
  6. After a change, test again with the same settings.

Check your own page

Run the free audit. It uses Lighthouse through PageSpeed Insights, so you get the same kind of report described here, in plain language and with the next step for each problem. To go further, run Lighthouse yourself in DevTools on pages behind a login or on your staging site.

Sources

Start here

Free website audit

Live Google data for any public page: mobile and desktop.

Mobile + desktop · Lighthouse lab test · Real-user Chrome data when Google has it

Rather have this done for you? Core Web Vitals · Book a call

Related guides

All guides →