seo-solver
v0.2.3
Published
SEO audit and comparison CLI tool
Readme
seo-solver
CLI tool for SEO audits, page-to-page comparisons, and extracting SEO data from HTML.
Use seo-solver to check titles, descriptions, canonical tags, Open Graph, JSON-LD, robots.txt, and other SEO signals from the terminal before a release, in CI, or while comparing production against a preview build.
seo-solver validate https://example.comWhy seo-solver?
SEO regressions are easy to miss. A template change can drop a canonical tag, break Open Graph data, or change structured data without anyone noticing until after release.
seo-solver helps answer three practical questions:
- what SEO data is on this page?
- does it pass validation?
- what changed between one version of a page and another?
Installation
seo-solver targets Node 22+ and is published as the seo-solver CLI package.
You can use the CLI without installing it globally, or install it with the package manager you already use.
Run without installing
pnpm
pnpm dlx seo-solver validate https://example.comnpm
npx seo-solver validate https://example.comYarn
yarn dlx seo-solver validate https://example.comBun
bunx seo-solver validate https://example.comInstall globally
pnpm
pnpm add -g seo-solvernpm
npm install -g seo-solverYarn
yarn global add seo-solverBun
bun add --global seo-solverOptional Playwright backend
If you need browser-backed fetching for JavaScript-heavy pages, install the optional Playwright backend and browser binaries with your package manager of choice:
pnpm
pnpm add -g @seo-solver/fetch-playwright playwright
pnpm exec playwright installnpm
npm install -g @seo-solver/fetch-playwright playwright
npx playwright installYarn
yarn global add @seo-solver/fetch-playwright playwright
yarn playwright installBun
bun add --global @seo-solver/fetch-playwright playwright
bunx playwright installQuick start
Validate a page:
seo-solver validate https://example.comCompare production and preview:
seo-solver compare https://example.com https://preview.example.comExtract normalized SEO data as JSON:
seo-solver extract https://example.com --format jsonPrint the current validation rule catalog:
seo-solver list-rulesCommands
| Command | Purpose |
| --- | --- |
| seo-solver validate <url> | Validate one page against SEO rules |
| seo-solver compare <url-a> <url-b> | Compare SEO data between two pages |
| seo-solver extract <url> | Extract normalized SEO data without validation |
| seo-solver list-rules | Print the available validation rules |
Common use cases
Check a page before release
seo-solver validate https://preview.example.comUse this before shipping a landing page, article, product page, or generated HTML.
Compare production and a new version
seo-solver compare https://example.com https://preview.example.comUse this to spot unexpected changes in title, description, canonical, Open Graph, JSON-LD, robots.txt, and other extracted targets.
Extract SEO data for scripts or CI
seo-solver extract https://example.com --targets meta,opengraph,jsonld --format jsonUse this when you want structured output for automation or custom checks.
Open artifacts in your editor
seo-solver extract https://example.com --editor codeBuilt-in editor presets are code, cursor, surf, and zed.
Browser-backed fetching
By default, the CLI uses the native fetcher. For pages that need browser-like behavior, install the optional Playwright backend and run:
seo-solver validate https://example.com --fetcher playwrightMore examples
# Compare only selected targets
seo-solver compare https://example.com https://preview.example.com --targets opengraph,meta
# Validate with pure JSON-LD validation (default)
seo-solver validate https://example.com --jsonld-runtime off
# Disable selected rules
seo-solver validate https://example.com --disable-rules opengraph/*
# Override rule severity
seo-solver validate https://example.com --severity-override opengraph/description-missing=error
# Keep normal compare output and also open diff artifacts in VS Code
seo-solver compare https://example.com https://preview.example.com --format json --editor codeDocumentation
- CLI reference
- CLI internals
- Monorepo conventions
- packages/fetch
- packages/fetch-playwright
- packages/extract
- packages/compare
- packages/validate
- packages/report
- packages/types
License
MIT
