Quick Start

Audit a URL

Run Web Guard against any URL to check all quality pillars:

bash
npx web-guard --url https://your-site.com

Sample Output

Web Guard reports each pillar with pass/fail status and violations:

bash
web-guard
URL: https://your-site.com
Device: mobile
✔ PERFORMANCE Score: 92
✔ A11Y Score: 95
✖ SEO Score: 70
[serious] Page is missing <meta name="description">
→ Add <meta name="description"> with a compelling summary.
[moderate] Page is missing <link rel="canonical">
→ Add <link rel="canonical"> to prevent duplicate content issues.
✔ SCHEMA Score: 100
✖ SECURITY Score: 40
[serious] Missing content-security-policy header
[serious] Missing strict-transport-security header
✖ 2 of 5 pillars failed (score: 79)

Use a Preset

Presets configure which pillars to run and their thresholds:

bash
# Lenient — performance, a11y, seo only, score >= 60
npx web-guard --url https://your-site.com --preset lenient
# Recommended — 5 pillars, score >= 80
npx web-guard --url https://your-site.com --preset recommended
# Strict — all 6 pillars, score >= 90
npx web-guard --url https://your-site.com --preset strict

Run Specific Pillars

bash
npx web-guard --url https://your-site.com --pillars performance,seo,a11y

Add to CI Pipeline

Add Web Guard to your GitHub Actions workflow:

yaml
- name: Setup Chrome
uses: browser-actions/setup-chrome@v1
- name: Web Quality Audit
run: npx web-guard --url ${{ env.DEPLOY_URL }} --preset recommended --ci
Web Guard exits with code 1 when any pillar fails, which will fail your CI build automatically.