Lighthouse-backed performance history tracker for a portfolio of client sites. See which sites are slow, why, and whether several sites share the same root cause. Works standalone or as an OpenClaw skill.
- runs Lighthouse against any site (by name from
sites.json, a bare domain, or a full URL) and stores the result - reports all six Lighthouse performance metrics (FCP, LCP, Speed Index, TTI, TBT, CLS), rated against Google's published thresholds, not just the aggregate score
- diagnostics: server response time (TTFB), DOM size, network request/byte totals, named third-party origin impact, legacy/duplicated JavaScript, HTTP/1.1 usage
- security checks: HTTPS, HSTS, CSP against XSS
--device mobile|desktop|both: run either or both of Lighthouse's real device presets- tracks performance score history per site and per device, with a trend indicator and a comparison against the previous run
- correlates shared render-blocking resources across sites, per device (e.g. the same theme/plugin asset slowing down several client sites at once)
- attaches an optional note to a run (e.g. "deployed plugin update") to trace a regression back to a change
--jsonflag on all commands for agents and scripts
- Node 22+
- Google Chrome or Chromium installed locally (Lighthouse drives a headless instance via
chrome-launcher) - pnpm (only for local development)
better-sqlite3 ships prebuilt binaries for macOS, Linux, and Windows (x64 and arm64), so no compiler toolchain is needed to install.
npm install -g siteclaw
or, for local development:
git clone https://github.com/psandis/siteclaw.git
cd siteclaw
pnpm install
pnpm build# sites.json: array of sites to track echo '[{ "name": "client-a", "url": "https://client-a-domain.com" }]' > sites.json siteclaw check client-a --note "deployed plugin update" siteclaw check https://example.com # one-off check, no sites.json entry needed siteclaw list siteclaw history client-a siteclaw correlate
(Running from a clone instead of a global install? Use pnpm dev <command> in place of siteclaw <command>.)
siteclaw check techcrunch
Running Lighthouse (mobile) against https://techcrunch.com...
techcrunch [mobile]: performance score 61
Diagnosis: Largest Contentful Paint is 4436ms (poor) with a fast server (TTFB 17ms): the delay is happening client-side after the server has already responded. Check for a slow-loading render-blocking resource, redirect, or content waiting on a client-side request. Published research on web performance generally (not a claim about this specific site): a 100ms delay has been linked to roughly a 7% drop in conversions, a 1-second delay on e-commerce pages to up to a 20% drop, and sites taking over 3 seconds to load see roughly 53% of mobile visitors abandon before it finishes (Google/Akamai-SOASTA; Deloitte/Google 2020).
Core metrics:
First Contentful Paint: 2251ms (needs improvement)
Largest Contentful Paint: 4436ms (poor)
Speed Index: 10337ms (poor)
Time to Interactive: 31373ms (poor)
Total Blocking Time: 439ms (needs improvement)
Cumulative Layout Shift: 0.064 (good)
Opportunities:
Reduce unused CSS: Reduce unused rules from stylesheets and defer CSS not used for above-the-fold content to decrease bytes consumed by network activity. [Learn how to reduce unused CSS](https://developer.chrome.com/docs/lighthouse/performance/unused-css-rules/). (160ms potential savings)
Reduce unused JavaScript: Reduce unused JavaScript and defer loading scripts until they are required to decrease bytes consumed by network activity. [Learn how to reduce unused JavaScript](https://developer.chrome.com/docs/lighthouse/performance/unused-javascript/).
Avoid enormous network payloads: Large network payloads cost users real money and are highly correlated with long load times. [Learn how to reduce payload sizes](https://developer.chrome.com/docs/lighthouse/performance/total-byte-weight/).
Diagnostics:
Server response time (TTFB): 17ms
DOM elements: 7118
Network requests: 212 (3.9MB transferred)
Unnecessary legacy JS (old-browser polyfills/transforms): 25.1KB
Third-party impact (main-thread time):
Google Tag Manager: 102ms, 521.5KB
Google CDN: 60ms, 347.4KB
Facebook: 52ms, 189.9KB
servenobid.com: 40ms, 438.2KB
Clarity: 39ms, 26.9KB
Security:
HTTPS: yes
HSTS header: present
CSP against XSS: configured
Vs. previous check (2026-09-16T22:36:52.911Z): score up 2, LCP -20ms
Notes:
- accepts either a name from
sites.json, a bare domain (www.example.com), or a fullhttp(s)://URL; nosites.jsonentry required for the latter two --note <text>attaches a note to the run, useful for tracing a later regression back to a specific change--device mobile|desktop|both: defaults tomobile(Lighthouse's own default, and how most real-world traffic arrives);bothruns and reports each device separately, each compared against its own device-specific history- Diagnosis synthesizes the metrics into one root-cause line instead of leaving you to interpret a list of numbers. It checks, in order: server response time (TTFB), since a slow server delays everything downstream and no front-end fix can compensate for it; then poor Total Blocking Time (weighted 30% in Lighthouse's own score), blamed on the heaviest third-party origin if one is reported, otherwise on the site's own JavaScript; then a client-side LCP delay when the server itself is fast. The general research context (conversion/bounce-rate impact of load-time delay) is cited from Google/Akamai-SOASTA and the Deloitte/Google 2020 mobile speed study. These are general industry findings, not a prediction for your specific site, and only appear when something is genuinely poor.
- metric ratings (good / needs improvement / poor) use Google's own published Core Web Vitals / Lighthouse thresholds, including TTFB (good ≤800ms, poor >1800ms, per web.dev)
- server response time shows
unavailablewhen Lighthouse could not measure it for that run, and the diagnosis then makes no server-side verdict - legacy/duplicated JavaScript and HTTP/1.1 usage only print when non-zero, so a clean result doesn't clutter the output
- render-blocking resources come from Lighthouse's
render-blocking-insightaudit; opportunity savings show milliseconds and/or bytes, whichever Lighthouse reports - security checks (HTTPS, HSTS, CSP) come from Lighthouse's
best-practicescategory, run alongsideperformance - the "vs. previous check" line is skipped for the metric comparison (score still shown) if the previous run predates core-metrics tracking, rather than showing a misleading diff against missing data
siteclaw list
nasa mobile 64 2026-09-16T20:46:54.909Z
rollingstone mobile 21 2026-09-16T20:47:12.956Z
techcrunch mobile 61 2026-09-16T22:37:21.115Z
Notes:
- one row per site per device (latest run of each); a site checked with
--device bothappears once asmobileand once asdesktop - only shows sites currently listed in
sites.json; older runs for sites removed from that file stay in the database but are hidden here
siteclaw history techcrunch
[mobile]
2026-09-16T20:46:40.141Z 37
2026-09-16T21:48:00.486Z 42 note: second check for real history example
2026-09-16T22:07:20.149Z 44
2026-09-16T22:09:31.502Z 34
2026-09-16T22:12:13.034Z 46
2026-09-16T22:26:42.655Z 36
2026-09-16T22:35:05.269Z 58
2026-09-16T22:36:25.673Z 42
2026-09-16T22:36:52.911Z 59
2026-09-16T22:37:21.115Z 61
Trend: up 2
Notes:
- runs are grouped per device, each with its own trend; mobile and desktop scores come from different throttling/emulation and are never compared against each other
--device mobile|desktopshows only that device- the trend compares the two most recent runs of that device
siteclaw correlate
No shared render-blocking resources found across sites.
Notes:
- compares the latest run of every site currently in
sites.json, separately per device (--device mobile|desktopto limit to one) - flags render-blocking resource URLs that appear on more than one site, usually a shared theme or plugin asset. When two sites share one, the output reads
Shared render-blocking resources (<device>):followed by<url> -> affects: <site-a>, <site-b>. - the example above was produced from runs recorded before 0.2.3, which stored no render-blocking resources (see CHANGELOG); re-run
checkon your sites forcorrelateto have data to compare
All defaults live in siteclaw.config.json at the project root. No code changes needed to:
- change where the SQLite database (
dbPath) or site list (sitesPath) live - change which Lighthouse audits (
opportunityAudits) get surfaced as opportunities
{
"dbPath": "siteclaw.db",
"sitesPath": "sites.json",
"opportunityAudits": [
"image-delivery-insight",
"unused-css-rules",
"unused-javascript",
"total-byte-weight"
]
}If the file is missing, these same values are used as built-in defaults. Every opportunityAudits ID must exist in the installed Lighthouse version; an unknown ID is silently skipped. Lighthouse 13 replaced several classic audits with *-insight audits (for example uses-optimized-images became image-delivery-insight).
All commands support --json for structured output:
siteclaw --json check techcrunch
siteclaw --json list
siteclaw --json history techcrunch
siteclaw --json correlateOnce installed globally (npm install -g siteclaw), add a SKILL.md to your workspace:
--- name: siteclaw description: Lighthouse performance history tracker for a portfolio of client sites version: 0.2.3 requires_binaries: - siteclaw --- When the user asks about site performance, regressions, or shared issues across client sites, use the `siteclaw` CLI: - To check a site: `siteclaw --json check <site-or-url>` - To list all tracked sites: `siteclaw --json list` - To see history for one site: `siteclaw --json history <site>` (returns `{ site, devices: [{ device, runs, trend }] }`) - To find shared issues across sites: `siteclaw --json correlate` (each entry has `device`, `url`, `sites`)
pnpm test runs the Vitest suite in tests/:
db.test.ts: SQLite storage, per-device history and latest-run queries, legacy-row fallbackssites.test.ts:sites.jsonloading and site-name / URL / bare-domain resolutionconfig.test.ts: defaults andsiteclaw.config.jsonoverridescorrelate.test.ts: cross-site shared render-blocking resource detectiondiagnosis.test.ts: root-cause diagnosis priority and wordingratings.test.ts: good / needs improvement / poor thresholdsthird-party.test.ts: third-party origin ordering and top-five cutaudit-data.test.ts: safe reading of Lighthouse audit details (missing fields, wrong types)
Lighthouse itself is not mocked or covered by automated tests: it requires a real headless Chrome and a real network call, so it's verified manually via siteclaw check against a real URL instead.
TypeScript/Node, lighthouse + chrome-launcher for measurement, better-sqlite3 for storage, commander for the CLI, vitest for tests, biome for lint/format, pnpm as package manager.
- 🦀 Dietclaw: Codebase health monitor
- 🦀 Dustclaw: Find out what is eating your disk space
- 🦀 Driftclaw: Deployment drift detection across environments
- 🦀 Feedclaw: RSS/Atom feed reader and AI digest builder
- 🦀 OpenClaw: The open claw ecosystem
See MIT