My Agent Called the SEO Bug Eight Hours Before Google Did

Brett Ridenour Brett Ridenour · May 29, 2026

Yesterday evening I was poking at why a few of my blog posts had fallen off Google. Impressions trickling, the homepage doing all the work, a couple of recent posts I knew were indexed last week now showing zero clicks for a week. Not a crisis. Just the kind of itch you scratch when you have a CLI sitting there.

I have a gsc command wired up that gives any agent in any session direct access to Google Search Console. I wrote about building it a few weeks ago. Five subcommands, no flags. gsc report brettridenour.com dumps the last 28 days into your terminal. gsc index brettridenour.com walks the sitemap and inspects every URL.

So I asked Claude to look.

The session

The prompt was lazy on purpose:

something's off with brettridenour.com indexing.
run gsc report and gsc index, then tell me what's wrong.

Claude ran both. The report came back fine — sitemap submitted, 91 URLs in it, 53 impressions over 28 days, the homepage taking most of the clicks. Then gsc index started chewing through URL Inspection calls one at a time (the API is rate-limited and there’s no batch endpoint, so it really does take a minute).

Halfway through, Claude stopped and flagged something I hadn’t asked it to look at:

That was the read. The site is a Domain property in GSC, which means both brettridenour.com and www.brettridenour.com belong to me. Vercel does a 308 from the naked domain to the www version. Normally fine. But somewhere — and Claude went off to figure out where — the naked-domain URLs were being submitted as canonical, getting crawled, hitting the 308, and Google was filing them under “Page with redirect” instead of indexing the www version.

It guessed the culprit was either a stale sitemap entry or a hardcoded https://brettridenour.com/... link in an older blog post pointing at itself. Two specific places to look. I bookmarked the diagnosis, closed the laptop, went to bed.

Claude diagnosing the redirect bucket mid-session

The email

This morning, before I’d even made coffee:

Google's morning alert email

That was the exact phrase Claude used eight hours earlier. Not “redirect chain” or “soft 404” — page with redirect, the specific GSC bucket. The agent had read the URL Inspection response, understood the verdict taxonomy, and named the failure mode before Google’s batch job had even queued the alert email.

Top issue: Page with redirect. Affected pages discovered, not currently indexed.

— GSC email, 6:43 AM

Timeline

  1. 2026-05-28 22:14
    I asked Claude to diagnose
    Prompt: 'something is off with indexing — run gsc report and gsc index'
  2. 2026-05-28 22:19
    Claude flagged 'Page with redirect'
    Mid-loop through URL Inspection. Named the GSC verdict bucket exactly, before being asked to interpret.
  3. 2026-05-28 22:23
    Claude proposed two fix candidates
    Either a sitemap entry pointing at the naked domain, or an internal link in an old post hardcoding https://brettridenour.com
  4. 2026-05-29 06:43
    Google's alert email arrived
    Same bucket name, same root cause. Eight hours behind the agent.

What actually made this work

I want to be careful here. This was not Claude predicting the future. It was Claude reading evidence I already had access to but hadn’t bothered to read myself. The URL Inspection API returns a structured coverageState field on every response. The string "Page with redirect" was literally in the JSON, dozens of times, every time I’d run gsc index over the last month. I’d just never scrolled long enough to notice the pattern.

What Claude did was the unsexy thing:

  1. Ran the diagnostic command I told it to run.
  2. Read every line of the output instead of skimming.
  3. Noticed a repeated value in a field I hadn’t asked about.
  4. Cross-referenced it against what it knows about GSC verdict taxonomy.
  5. Named the bucket Google uses, because that’s the bucket Google uses.

The “prediction” was just a head start on reading mail Google had already drafted. Which, when you think about it, is what makes this kind of agent actually useful — not magical foresight, but the thing you would have caught if you’d been disciplined enough to read the whole output of every command you ran.

The fix

The bug, once Claude went looking in daylight, turned out to be the dumber of the two candidates. An old blog post had an internal link written as https://brettridenour.com/blog/... instead of a relative /blog/.... Google had crawled it, followed the link, hit the 308, and filed the destination URL under “discovered but not indexed because the canonical URL is a redirect.”

One sed, one commit, one re-submit. Probably fixed in two weeks once Google recrawls.

The takeaway

The pattern worth stealing here isn’t “use Claude for SEO.” It’s the shape of the tool. gsc is five subcommands. It returns plain text. The agent doesn’t need an SDK, it needs a bash it already knows how to type and an output it can read line by line.

If you have a system you check by hand every week or two — Stripe, your error tracker, your hosting provider’s status page, anything — write the dumb CLI version of it tonight. Three subcommands. No flags. Pipe the output to your agent and ask “anything weird?”

You’ll be surprised how often the answer is “yes, and here is the specific bucket the vendor’s alert email is about to use.”