SEO Drift Monitor (April 2026)

SEO drift monitoring: capture baselines of SEO-critical elements, detect changes, and track regressions over time.

How to use it

  1. Hit Copy SKILL.md — or use the Claude Code line below to get every file.
  2. Claude: ⋯ → Download .md, then Customize → Skills → Add → Upload skill.
    ChatGPT: make a Project and paste it into Instructions.
    Neither? Paste it at the top of a new chat — it works for that chat.
  3. Describe your job in plain words. The AI follows the skill from there.
Claude Code — installs the whole folder, not just SKILL.md
npx degit AgriciDaniel/claude-seo/skills/seo-drift#main ~/.claude/skills/seo-drift

For one project only, change the path to .claude/skills/seo-drift. This skill also uses parse_html.py, pagespeed_check.py, fetch_page.py, drift_baseline.py, drift_compare.py, drift_report.py — copying SKILL.md alone won't be enough. See the folder on GitHub.

Not working?
  • Check which app you pasted it into — the steps above name the right one.
  • Some skills need the paid tier of Claude or ChatGPT.
Step-by-step guide with screenshots · Ask in the forum

Paste into Claude, ChatGPT or Cursor.

Show the full text220 lines
seo-drift/SKILL.md220 lines7.2 KBpushed 11d agoRawView on GitHub

SEO Drift Monitor (April 2026)

Git for your SEO. Capture baselines, detect regressions, track changes over time.


Commands

Command Purpose
/seo drift baseline <url> Capture current SEO state as a "known good" snapshot
/seo drift compare <url> Compare current page state to stored baseline
/seo drift history <url> Show change history and past comparisons

What It Captures

Every baseline records these SEO-critical elements:

Element Field Source
Title tag title parse_html.py
Meta description meta_description parse_html.py
Canonical URL canonical parse_html.py
Robots directives meta_robots parse_html.py
H1 headings h1 (array) parse_html.py
H2 headings h2 (array) parse_html.py
H3 headings h3 (array) parse_html.py
JSON-LD schema schema (array) parse_html.py
Open Graph tags open_graph (dict) parse_html.py
Core Web Vitals cwv (dict) pagespeed_check.py
HTTP status code status_code fetch_page.py
HTML content hash html_hash (SHA-256) Computed
Schema content hash schema_hash (SHA-256) Computed

How Comparison Works

The comparison engine applies 17 rules across 3 severity levels. Load references/comparison-rules.md for the full rule set with thresholds, recommended actions, and cross-skill references.

Severity Levels

Level Meaning Response Time
CRITICAL SEO-breaking change, likely traffic loss Immediate
WARNING Potential impact, needs investigation Within 1 week
INFO Awareness only, may be intentional Review at convenience

Storage

All data is stored locally in SQLite:

~/.cache/claude-seo/drift/baselines.db

Tables

  • baselines: Captured snapshots with all SEO elements
  • comparisons: Diff results with triggered rules and severities

URL normalization ensures consistent matching: lowercase scheme/host, strip default ports (80/443), sort query parameters, remove UTM parameters, strip trailing slashes.


Command: baseline

Captures the current state of a page and stores it.

Steps:

  1. Validate URL (SSRF protection via google_auth.validate_url())
  2. Fetch page via "${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run fetch_page.py <URL>
  3. Parse HTML via "${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run parse_html.py <URL>
  4. Optionally fetch CWV via "${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run pagespeed_check.py <URL> (use --skip-cwv to skip)
  5. Hash HTML body and schema content (SHA-256)
  6. Store snapshot in SQLite

Execution:

"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_baseline.py <url>
"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_baseline.py <url> --skip-cwv

Output: JSON with baseline ID, timestamp, URL, and summary of captured elements.


Command: compare

Fetches the current page state and diffs it against the most recent baseline.

Steps:

  1. Validate URL
  2. Load most recent baseline from SQLite (or specific --baseline-id)
  3. Fetch and parse current page state
  4. Run all 17 comparison rules
  5. Classify findings by severity
  6. Store comparison result
  7. Output JSON diff report

Execution:

"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_compare.py <url>
"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_compare.py <url> --baseline-id 5
"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_compare.py <url> --skip-cwv

Output: JSON with all triggered rules, old/new values, severity, and actions.

After comparison, offer to generate an HTML report:

"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_report.py <comparison_json_file> --output drift-report.html

Command: history

Shows all baselines and comparisons for a URL.

Execution:

"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_history.py <url>
"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_history.py <url> --limit 10

Output: JSON array of baselines (newest first) with timestamps and comparison summaries.


Cross-Skill Integration

When drift is detected, recommend the appropriate specialized skill:

Finding Recommendation
Schema removed or modified Run /seo schema <url> for full validation
CWV regression Run /seo technical <url> for performance audit
Title or meta description changed Run /seo page <url> for content analysis
Canonical changed or removed Run /seo technical <url> for indexability check
Noindex added Run /seo technical <url> for crawlability audit
H1/heading structure changed Run /seo content <url> for E-E-A-T review
OG tags removed Run /seo page <url> for social sharing analysis
Status code changed to error Run /seo technical <url> for full diagnostics

Error Handling

Scenario Action
URL unreachable Report error from fetch_page.py. Do not guess state. Suggest user verify URL.
No baseline exists for URL Inform user and suggest running baseline first.
SSRF blocked (private IP) Report validate_url() rejection. Never bypass.
SQLite database missing Auto-create on first use. No error.
CWV fetch fails (no API key) Store null for CWV fields. Skip CWV rules during comparison.
Page returns 4xx/5xx Still capture as baseline (status code IS a tracked field).
Multiple baselines exist Use most recent unless --baseline-id specified.

Security

  • All URL fetching goes through "${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run fetch_page.py, which enforces SSRF protection (blocks private IPs, loopback, reserved ranges, GCP metadata endpoints)
  • No curl, no subprocess HTTP calls -- only the project's validated fetch pipeline
  • All SQLite queries use parameterized placeholders (?), never string interpolation
  • TLS always verified -- no verify=False anywhere in the pipeline

Typical Workflows

Pre/Post Deployment Check

/seo drift baseline https://example.com     # Before deploy
# ... deploy happens ...
/seo drift compare https://example.com      # After deploy

Ongoing Monitoring

/seo drift baseline https://example.com     # Initial capture
# ... weeks later ...
/seo drift compare https://example.com      # Check for drift
/seo drift history https://example.com      # Review all changes

Investigating a Traffic Drop

/seo drift compare https://example.com      # What changed?
/seo drift history https://example.com      # When did it change?
1---
2name: seo-drift
3description: >
4 SEO drift monitoring: capture baselines of SEO-critical elements, detect changes,
5 and track regressions over time. Git for SEO: baseline, diff, and track changes
6 to your on-page SEO. Use when user says "SEO drift", "baseline", "track changes",
7 "did anything break", "SEO regression", "compare SEO", "before and after",
8 "monitor SEO changes", or "deployment check".
9user-invocable: true
10argument-hint: "baseline|compare|history <url>"
11license: MIT
12metadata:
13 author: AgriciDaniel
14 original_author: "Dan Colta (Pro Hub Challenge)"
15 version: "2.3.1"
16 category: seo
17---
18 
19# SEO Drift Monitor (April 2026)
20 
21Git for your SEO. Capture baselines, detect regressions, track changes over time.
22 
23---
24 
25## Commands
26 
27| Command | Purpose |
28|---------|---------|
29| `/seo drift baseline <url>` | Capture current SEO state as a "known good" snapshot |
30| `/seo drift compare <url>` | Compare current page state to stored baseline |
31| `/seo drift history <url>` | Show change history and past comparisons |
32 
33---
34 
35## What It Captures
36 
37Every baseline records these SEO-critical elements:
38 
39| Element | Field | Source |
40|---------|-------|--------|
41| Title tag | `title` | `parse_html.py` |
42| Meta description | `meta_description` | `parse_html.py` |
43| Canonical URL | `canonical` | `parse_html.py` |
44| Robots directives | `meta_robots` | `parse_html.py` |
45| H1 headings | `h1` (array) | `parse_html.py` |
46| H2 headings | `h2` (array) | `parse_html.py` |
47| H3 headings | `h3` (array) | `parse_html.py` |
48| JSON-LD schema | `schema` (array) | `parse_html.py` |
49| Open Graph tags | `open_graph` (dict) | `parse_html.py` |
50| Core Web Vitals | `cwv` (dict) | `pagespeed_check.py` |
51| HTTP status code | `status_code` | `fetch_page.py` |
52| HTML content hash | `html_hash` (SHA-256) | Computed |
53| Schema content hash | `schema_hash` (SHA-256) | Computed |
54 
55---
56 
57## How Comparison Works
58 
59The comparison engine applies **17 rules across 3 severity levels**. Load
60`references/comparison-rules.md` for the full rule set with thresholds,
61recommended actions, and cross-skill references.
62 
63### Severity Levels
64 
65| Level | Meaning | Response Time |
66|-------|---------|---------------|
67| **CRITICAL** | SEO-breaking change, likely traffic loss | Immediate |
68| **WARNING** | Potential impact, needs investigation | Within 1 week |
69| **INFO** | Awareness only, may be intentional | Review at convenience |
70 
71---
72 
73## Storage
74 
75All data is stored locally in SQLite:
76 
77```
78~/.cache/claude-seo/drift/baselines.db
79```
80 
81### Tables
82 
83- **baselines**: Captured snapshots with all SEO elements
84- **comparisons**: Diff results with triggered rules and severities
85 
86URL normalization ensures consistent matching: lowercase scheme/host, strip
87default ports (80/443), sort query parameters, remove UTM parameters, strip
88trailing slashes.
89 
90---
91 
92## Command: `baseline`
93 
94Captures the current state of a page and stores it.
95 
96**Steps:**
971. Validate URL (SSRF protection via `google_auth.validate_url()`)
982. Fetch page via `"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run fetch_page.py <URL>`
993. Parse HTML via `"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run parse_html.py <URL>`
1004. Optionally fetch CWV via `"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run pagespeed_check.py <URL>` (use `--skip-cwv` to skip)
1015. Hash HTML body and schema content (SHA-256)
1026. Store snapshot in SQLite
103 
104**Execution:**
105```bash
106"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_baseline.py <url>
107"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_baseline.py <url> --skip-cwv
108```
109 
110**Output:** JSON with baseline ID, timestamp, URL, and summary of captured elements.
111 
112---
113 
114## Command: `compare`
115 
116Fetches the current page state and diffs it against the most recent baseline.
117 
118**Steps:**
1191. Validate URL
1202. Load most recent baseline from SQLite (or specific `--baseline-id`)
1213. Fetch and parse current page state
1224. Run all 17 comparison rules
1235. Classify findings by severity
1246. Store comparison result
1257. Output JSON diff report
126 
127**Execution:**
128```bash
129"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_compare.py <url>
130"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_compare.py <url> --baseline-id 5
131"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_compare.py <url> --skip-cwv
132```
133 
134**Output:** JSON with all triggered rules, old/new values, severity, and actions.
135 
136After comparison, offer to generate an HTML report:
137```bash
138"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_report.py <comparison_json_file> --output drift-report.html
139```
140 
141---
142 
143## Command: `history`
144 
145Shows all baselines and comparisons for a URL.
146 
147**Execution:**
148```bash
149"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_history.py <url>
150"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run drift_history.py <url> --limit 10
151```
152 
153**Output:** JSON array of baselines (newest first) with timestamps and comparison summaries.
154 
155---
156 
157## Cross-Skill Integration
158 
159When drift is detected, recommend the appropriate specialized skill:
160 
161| Finding | Recommendation |
162|---------|----------------|
163| Schema removed or modified | Run `/seo schema <url>` for full validation |
164| CWV regression | Run `/seo technical <url>` for performance audit |
165| Title or meta description changed | Run `/seo page <url>` for content analysis |
166| Canonical changed or removed | Run `/seo technical <url>` for indexability check |
167| Noindex added | Run `/seo technical <url>` for crawlability audit |
168| H1/heading structure changed | Run `/seo content <url>` for E-E-A-T review |
169| OG tags removed | Run `/seo page <url>` for social sharing analysis |
170| Status code changed to error | Run `/seo technical <url>` for full diagnostics |
171 
172---
173 
174## Error Handling
175 
176| Scenario | Action |
177|----------|--------|
178| URL unreachable | Report error from `fetch_page.py`. Do not guess state. Suggest user verify URL. |
179| No baseline exists for URL | Inform user and suggest running `baseline` first. |
180| SSRF blocked (private IP) | Report `validate_url()` rejection. Never bypass. |
181| SQLite database missing | Auto-create on first use. No error. |
182| CWV fetch fails (no API key) | Store `null` for CWV fields. Skip CWV rules during comparison. |
183| Page returns 4xx/5xx | Still capture as baseline (status code IS a tracked field). |
184| Multiple baselines exist | Use most recent unless `--baseline-id` specified. |
185 
186---
187 
188## Security
189 
190- **All URL fetching** goes through `"${CLAUDE_PLUGIN_ROOT}/scripts/claude-seo" run fetch_page.py`, which enforces SSRF protection
191 (blocks private IPs, loopback, reserved ranges, GCP metadata endpoints)
192- **No curl, no subprocess HTTP calls** -- only the project's validated fetch pipeline
193- **All SQLite queries** use parameterized placeholders (`?`), never string interpolation
194- **TLS always verified** -- no `verify=False` anywhere in the pipeline
195 
196---
197 
198## Typical Workflows
199 
200### Pre/Post Deployment Check
201```
202/seo drift baseline https://example.com # Before deploy
203# ... deploy happens ...
204/seo drift compare https://example.com # After deploy
205```
206 
207### Ongoing Monitoring
208```
209/seo drift baseline https://example.com # Initial capture
210# ... weeks later ...
211/seo drift compare https://example.com # Check for drift
212/seo drift history https://example.com # Review all changes
213```
214 
215### Investigating a Traffic Drop
216```
217/seo drift compare https://example.com # What changed?
218/seo drift history https://example.com # When did it change?
219```
220 

Discussion

From GitHub

4 comments on 3 threads

Quick addendum: I'm aware there's a broader debate (see anthropics/claude-code#26179) that subagents shouldn't default to Opus/inherit since most focused, well-scoped subagent tasks do fine on Sonnet, and blanket-Opus wastes resources. I want to be clear that's not what I'm proposing here. This isn't "more Opus everywhere" — it's the opposite: keep Sonnet as the default for the 13 mechanical/extraction agents (backlinks, dataforseo, ecommerce, flow, google, image-gen, local, maps, performance, schema, sitemap, technical, visual), and only escalate the 5 agents whose job is genuinely open-endedread the rest

Follow-up: while applying the local tempfile workaround I hit two more Windows-specific bugs in the same `drift_baseline.py` → `parse_html.py` chain. All three are needed together for any non-Latin-1 content (e.g. Czech, German, French diacritics) to round-trip correctly on Windows. ## Bug 2 — `UnicodeEncodeError` when writing HTML to `parse_html.py` stdin After the tempfile patch, baselining any page containing non-Latin-1 characters fails with: (`Č` = `Č`, Czech capital C with caron. Same break for any character outside cp1252.) Root cause: `subprocess.run(..., input=html_content, text=True,read the rest

Alternatives

Also in SEO & keywords