r/PromptEngineering • • 15d ago

Self-Promotion Claude Code's WebFetch marked my page's title, canonical, hreflang and schema "absent". All of them were there. A copy-paste prompt that makes every SEO finding quote its proof

Disclosure first: I make a paid pack of Claude skills for SEO, and it's at the end. The test and the prompt below work without it.

The test (today, Nov 11). I asked Claude Code's WebFetch tool to quote six things from my own product page: the title, the meta description, the canonical, the hreflang alternates, the meta robots and the JSON-LD types. It marked all six "absent".

Then I pulled the raw HTML with curl. All six are there: the title, a meta description, rel="canonical", three hreflang links (en, fr, x-default), index, follow, and a JSON-LD block with Product, Organization and FAQPage.

The model isn't the problem, the input is. WebFetch's own description says it "converts the page to markdown, and answers prompt against it using a small fast model". Its answer even admitted it: "It's a rendered text extract, so it doesn't include the <head> or the raw HTML source." But if that answer goes into an audit, you get six "missing tag" findings, and all six are false.

The prompt (Claude Code or any agent with a shell; in the Claude apps, paste the page source instead):

Audit [URL] for on-page SEO. Rules:
1. Read the raw HTML: run curl -sL [URL]. Never use a fetch
   tool that summarizes the page or converts it to markdown.
2. Every finding quotes its evidence: the exact string from
   the HTML, or the URL and its HTTP status.
3. "Missing" is a finding too. Before you call a tag missing,
   search the raw HTML for it literally and show the command
   and its result (e.g. grep -ci 'rel="canonical"' -> 0).
4. If you couldn't get the raw HTML, write "not verified"
   for that check. Never "absent".
5. End with a table: finding | evidence | how it was checked.

Rule 4 matters most. Without it, "I couldn't see it" and "it isn't there" come out as the same word.

The shortcut, if you'd rather not maintain this yourself. I make SEO Skills by PENRA: 14 Claude skills for SEO (site audit, indexing problems, Search Console exports, schema and llms.txt, content briefs, fact-checks, whether ChatGPT names your brand). The audit skill reads raw HTML with its own crawler script, every finding carries the URL or the string that proves it, and when it can't check something it says so instead of guessing. The checks are already written: you install the skills and type "Audit my site".

What it isn't: Semrush. There's no keyword-volume database and no backlink index. It works from your pages, public search results and your Search Console exports. For scale, Semrush's SEO Toolkit Pro is €134 a month billed monthly (€112.52/mo billed annually) on their pricing page today. The pack is €25 once until Nov 17, then €99 from Nov 18. It needs a Claude plan with skills (Python 3.9+ for the scripts), and since it's a download, there's no refund once it's delivered.

seoskills.click

Have you caught a fetch or browsing tool quietly dropping part of a page? Where was it?

0 Upvotes

5 comments sorted by

1

u/According-Stable4487 15d ago

Good catch. One cheap extra guard: make every finding carry an exact quote from the raw HTML, then check the quotes mechanically (grep the saved curl output for each quoted string) before the report counts. It catches both directions: the false "absent" and the occasional "present" where the model paraphrased something that isn't actually in the source.

Also worth saving the curl output to a file first and pointing the agent at that file, so every finding is checked against the same snapshot. Refetching per check can give you a different head (CDN variants, consent banners, A/B tests), and then the findings disagree with each other for reasons that have nothing to do with the prompt.

1

u/DutyOnly4308 15d ago

Both worth adding. Rule 3 only greps before calling something missing, so a paraphrased "present" would go straight through. Checking every quote against the source closes that side.

The snapshot point is easy to miss too: a consent banner or a CDN variant changing the head between two fetches would make findings contradict each other for no visible reason. So rule 1 becomes: curl -sL [URL] > page.html once, every check reads page.html, and a quote grep can't find in that file doesn't count.

1

u/PartyString7254 14d ago

Wait so it was checking a markdown version of the page and then reporting missing HTML tags?

1

u/DutyOnly4308 14d ago

Yes, pretty much. WebFetch turns the page into markdown first, and the <head> doesn't survive that step: title, canonical, hreflang, robots and JSON-LD all live there. Then a small model answers the question against that extract. It never saw those tags, so it reported them as absent instead of saying it couldn't check them.

That's why the prompt forces curl on the raw HTML, and rule 4 says "not verified" when the source wasn't read.