# Lighthouse Bulk Audit: Core Web Vitals and scores for many URLs (`fecklesspleb/lighthouse-bulk-audit`) Actor

Run Google Lighthouse on a list of URLs or a sitemap, mobile and desktop: performance, accessibility, best-practices and SEO scores, LCP, CLS, TBT and the top fixes. Monitor mode flags score changes. No API key. $8 per 1,000 audits.

- **URL**: https://apify.com/fecklesspleb/lighthouse-bulk-audit.md
- **Developed by:** [fecklesspleb](https://apify.com/fecklesspleb) (community)
- **Categories:** SEO tools, Developer tools
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per event

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Lighthouse Bulk Audit: Core Web Vitals and Lighthouse scores for many URLs

Run Google Lighthouse on a list of URLs or a whole sitemap, on mobile and/or desktop, and get one row per page and device: the four Lighthouse category scores (performance, accessibility, best practices, SEO), the lab Core Web Vitals (LCP, CLS, TBT) and other metrics, and the top fixes with estimated savings. Monitor mode compares every page with the previous run and flags real changes.

Lighthouse runs inside the Actor in headless Chromium. No API key, no PageSpeed Insights quota, no Google account.

### What you get per page and device

- `performance`, `accessibility`, `bestPractices`, `seo`: Lighthouse scores, 0-100.
- `lcpMs`, `cls`, `tbtMs`, `fcpMs`, `speedIndexMs`, `serverResponseMs`, `totalByteWeight`, plus `metricScores` (each metric's own Lighthouse score, 0-1).
- `topFixes`: the biggest performance insights and diagnostics (title, Lighthouse score, estimated savings in ms and bytes).
- `otherIssues`: failed accessibility, best-practices and SEO checks, most important first.
- `lighthouseVersion`, `emulatedUserAgent`, `throttlingMethod`, `cpuBenchmarkIndex`, `runWarnings`, `auditSeconds`.
- Monitor mode adds `monitorStatus`, `changed`, `scoreChanges`, `previousScores` and `previousAuditAt`.

### Input

```json
{
  "urls": ["https://example.com/"],
  "formFactors": ["mobile"]
}
```

| Field | Default | Notes |
|---|---|---|
| `urls` | prefilled with `https://example.com/` | Page URLs. Duplicates are removed. |
| `sitemapUrl` | none | XML sitemap, `.xml.gz` or a sitemap index (up to 10 child sitemaps). |
| `formFactors` | `["mobile"]` | `mobile`, `desktop` or both. Each page is audited once per device. |
| `categories` | all four | `performance`, `accessibility`, `best-practices`, `seo`. |
| `maxUrls` | 10 | 1-1000 pages per run. |
| `maxFixes` | 5 | 0-20 entries in `topFixes` and `otherIssues`. |
| `perHostDelaySecs` | 2 | 0-60. Pause between audits of the same host (or the site's crawl-delay, up to 60 s). |
| `auditTimeoutSecs` | 120 | 60-300. A slower audit is stopped and not charged. |
| `includeFailed` | true | Free rows for skipped and failed pages. |
| `monitorName` | none | Same name on each scheduled run to compare with the last run. |
| `changeThreshold` | 5 | 1-50 score points that count as a change. |

### Output example

From a real local run of the default input (Lighthouse 13.6.0, 2026-11-11; some fields left out):

```json
{
  "url": "https://example.com/",
  "formFactor": "mobile",
  "finalUrl": "https://example.com/",
  "status": "ok",
  "performance": 100,
  "accessibility": 96,
  "bestPractices": 100,
  "seo": 80,
  "lcpMs": 891,
  "fcpMs": 783,
  "tbtMs": 58,
  "cls": 0,
  "speedIndexMs": 783,
  "serverResponseMs": 11,
  "totalByteWeight": 2000,
  "topFixes": [
    {"id": "cache-insight", "title": "Use efficient cache lifetimes", "displayValue": "Est savings of 1 KiB", "score": 0.5, "estimatedSavingsMs": 0, "estimatedSavingsBytes": 1477}
  ],
  "otherIssues": [
    {"category": "accessibility", "id": "landmark-one-main", "title": "Document does not have a main landmark."},
    {"category": "seo", "id": "meta-description", "title": "Document does not have a meta description"}
  ],
  "lighthouseVersion": "13.6.0",
  "throttlingMethod": "simulate",
  "auditSeconds": 6.3,
  "error": null
}
```

A page that is skipped or fails gets a free row such as `{"status": "skipped", "error": "not audited: robots.txt disallows this URL"}` or `{"status": "failed", "error": "Lighthouse: ERRORED_DOCUMENT_REQUEST: ..."}`.

### Pricing (proposal, not live)

**$0.008 per successful audit** (event `audit`; one page on one device), i.e. $8 per 1,000 audits, plus Apify's standard run-start event. Skipped and failed audits are free. Set a **maximum cost per run**: the Actor checks the budget before each audit and stops cleanly when the next one could not be paid for.

### How it behaves

- **robots.txt:** each page's site robots.txt is checked first (product token `LighthouseBulkAudit`, RFC 9309). Disallowed pages are skipped. If robots.txt cannot be read (server error, HTML instead of a robots file), the site is not audited. If the page redirects, the final URL must pass the same checks or the result is discarded and not charged.
- **Pacing:** one audit at a time (parallel audits on one machine distort performance scores), with a pause between audits of the same host and round-robin ordering across hosts.
- **Safety:** only public http(s) addresses are audited. Private, loopback and link-local addresses and URLs with a user name or password are refused. No cookies or logins: every audit starts a fresh Chromium profile.
- **Page load:** Chromium sends Lighthouse's standard emulated Chrome user agent (the same as PageSpeed Insights), so scores are comparable.

### Limits

- Lab data only. Lighthouse simulates a mid-range phone on slow 4G (mobile) or a desktop. Field data such as INP from real users (CrUX) is not included.
- Lighthouse scores vary from run to run, especially performance. Use monitor mode with a threshold of 5+ points for alerts.
- Scores depend on the CPU the audit runs on (`cpuBenchmarkIndex` is reported). They can differ from PageSpeed Insights for the same page.
- Pages behind logins, paywalls or bot protection are not audited. The Actor does not try to get around them.

### Is it legal?

The Actor loads pages the way a browser does, one at a time, obeys robots.txt and never logs in. Audit sites you own or are allowed to test. Lighthouse is open source (Apache-2.0).

### FAQ

**Can I run it on a schedule?** Yes. Create an Apify schedule and set `monitorName` so every run compares with the previous one.

**Can I call it from code or an AI agent?** Yes, through the Apify API, the Apify clients or Apify's MCP server.

# Changelog

This Actor's version history is a separate document: https://apify.com/fecklesspleb/lighthouse-bulk-audit/changelog.md

# Actor input Schema

## `urls` (type: `array`):

Pages to audit (sites you run or are allowed to test). Each site's robots.txt is respected; pages it disallows, private or local network addresses and URLs with a user name or password are skipped for free. Duplicates are removed.

## `sitemapUrl` (type: `string`):

An XML sitemap (or .xml.gz, or a sitemap index: up to 10 child sitemaps) whose page URLs are added to the list, up to Max. URLs.

## `formFactors` (type: `array`):

Each page is audited once per device. Mobile uses Lighthouse's default mobile emulation and simulated slow-4G throttling; desktop uses Lighthouse's desktop preset.

## `categories` (type: `array`):

Lighthouse categories to run. Fewer categories run a little faster; the price per audit is the same.

## `maxUrls` (type: `integer`):

At most this many pages per run (list plus sitemap). Audits = pages x devices.

## `maxFixes` (type: `integer`):

How many performance fixes (topFixes) and accessibility/best-practices/SEO issues (otherIssues) to list per audit.

## `perHostDelaySecs` (type: `integer`):

Audits of the same host are spaced at least this far apart (longer if the site's robots.txt asks for a crawl-delay, up to 60 s). Audits already run one at a time and each takes about 10-15 s.

## `auditTimeoutSecs` (type: `integer`):

An audit that takes longer is stopped and reported as failed (not charged).

## `includeFailed` (type: `boolean`):

Add a free row for each page that was skipped (robots.txt, private address) or failed (HTTP error, timeout).

## `monitorName` (type: `string`):

Give the same name on every scheduled run to compare each page's scores with the previous run. Letters, digits and ! - \_ . ' ( ) only. Scores are kept in the named key-value store lighthouse-bulk-audit-monitor in your account.

## `changeThreshold` (type: `integer`):

Monitor mode flags a page as changed when any category score moved by at least this many points. Lighthouse scores vary from run to run, so very small thresholds are noisy.

## Actor input object example

```json
{
  "urls": [
    "https://example.com/"
  ],
  "formFactors": [
    "mobile"
  ],
  "categories": [
    "performance",
    "accessibility",
    "best-practices",
    "seo"
  ],
  "maxUrls": 10,
  "maxFixes": 5,
  "perHostDelaySecs": 2,
  "auditTimeoutSecs": 120,
  "includeFailed": true,
  "changeThreshold": 5
}
```

# Actor output Schema

## `audits` (type: `string`):

No description

## `summary` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "urls": [
        "https://example.com/"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("fecklesspleb/lighthouse-bulk-audit").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "urls": ["https://example.com/"] }

# Run the Actor and wait for it to finish
run = client.actor("fecklesspleb/lighthouse-bulk-audit").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "urls": [
    "https://example.com/"
  ]
}' |
apify call fecklesspleb/lighthouse-bulk-audit --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,fecklesspleb/lighthouse-bulk-audit"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/WwTkmA22pfg6UgK8Y/builds/BTxosf9dgf6olbEF6/openapi.json
