Resources · AI Visibility Tools

How to Use Claude Code for SEO and GEO Audits

Claude Code can handle much of a technical SEO and GEO audit. It is Anthropic's agentic coding tool: it runs in your terminal, reads and writes files, runs commands and fetches web pages. You describe the checks you want, and it writes and runs the scripts. It can fetch pages as AI crawlers see them, test robots.txt and firewall access, extract structured data, and scan server logs for AI crawlers. It can then compile the findings into a report. It works best for sites up to a few thousand pages, and every finding it reports should be checked against the evidence it produced.

What can Claude Code do in an audit?

Because it can run commands and write code, Claude Code can do most checks that a technical auditor would script by hand:

  • Access checks: read robots.txt and report rules for each AI crawler; fetch key pages with different user agents and compare status codes.
  • Rendering checks: compare the raw HTML with the rendered page, using a headless browser if you have one installed, to find content that only appears after JavaScript runs.
  • Crawl basics: parse sitemaps, follow internal links, and report status codes, redirect chains, canonical tags and noindex directives.
  • Structured data: extract JSON-LD from each page and check that key properties match the visible text.
  • Content structure: list headings, check whether pages open with a direct answer, and flag facts that appear only in images.
  • Log analysis: scan server logs for AI crawler user agents and summarise which pages they fetch and what responses they receive.
  • Question-to-page mapping: take your list of buyer questions and match each to the page that best answers it, flagging gaps.
  • Reporting: write the findings into a structured report with evidence for each item.

How do you set it up for audit work?

  1. Create an audit folder for each site, with subfolders for raw data, scripts and reports.
  2. Write a CLAUDE.md file in the folder describing the audit: the site, the checks you want, where to save outputs, and rules such as "save raw evidence for every finding" and "do not modify anything on the live site".
  3. Add your inputs: a list of key URLs, your buyer questions, and any server log exports.
  4. Keep permissions tight. Review commands before approving them, especially anything that sends requests at scale.
  5. Ask for scripts, not just answers. Scripts can be re-run next month for a like-for-like comparison.

What does an example audit task look like?

A prompt for the access check might be:

"Read robots.txt for example.com and list the rules that apply to GPTBot, OAI-SearchBot, ChatGPT-User, ClaudeBot, Claude-User, Claude-SearchBot, PerplexityBot, Perplexity-User, Google-Extended and Bingbot. Then fetch the 20 URLs in key-urls.txt with each of those user agents except Google-Extended, which is a robots.txt token with no user agent of its own (use Googlebot instead), record the status code and response size, and save the results to data/access.csv. Flag any URL where a crawler gets a non-200 response or a much smaller page than a normal browser."

And for rendering:

"For each URL in key-urls.txt, save the raw HTML text and the text after rendering with a headless browser. Report pages where the rendered text contains more than 30% more words than the raw HTML, and list the missing headings."

Each task produces files you can open and check, not just a summary.

Which GEO-specific checks are most useful?

  • Crawler-by-crawler access, since many sites allow Googlebot but block AI crawlers through a CDN or security plugin; see how to audit your website for AI visibility gaps from its URL.
  • Content visible without JavaScript, because many AI crawlers do not render scripts.
  • Answer placement: whether each key page answers its main question in the opening paragraph, with specifics.
  • Fact consistency: whether prices, hours, addresses and product details match across pages, structured data and any listings you export.
  • Question coverage: which buyer questions have no page that answers them directly.
  • Log evidence: whether AI crawlers actually fetch your key pages, and how often.

For the full list of what a GEO audit should cover, including checks on AI answers themselves, see what a GEO checklist or audit template should include.

Can Claude Code check what AI engines say about the site?

Partly. With its Chrome integration, Claude Code can open ChatGPT, Gemini or Perplexity in your own browser, ask a question and record the answer and sources, which is useful for spot checks; check each service's terms before automating it, and expect it to be slow. For repeatable runs, ask it to write a script that calls engines' developer APIs with your own keys, run a fixed set of questions several times, and log answers and cited sources. Leave Gemini out of logged runs: Google's grounding terms forbid storing or analysing grounded results, so keep Gemini to manual spot checks. Those API answers can differ from what app users see, so check a sample by hand. For the method, see how to batch-test AI visibility queries with an API instead of buying a tool.

How do you keep the results trustworthy?

  • Treat user-agent tests as a first pass. Firewalls and CDNs often identify AI crawlers by their published IP ranges, so a request with a borrowed user agent from your machine can be treated differently from the real bot. Confirm with server or CDN logs showing requests from the crawlers' published IPs and the status codes they received.
  • Require evidence files for every finding: the raw HTML, the status code log, the extracted JSON-LD.
  • Spot-check findings against the evidence and against the live site in a browser.
  • Watch for confident summaries of checks that did not actually run, for example when a request failed. Ask it to show the command output behind any surprising claim.
  • Re-run scripts rather than asking for a fresh analysis each month, so results are comparable.
  • Be polite to the site: limit request rates, especially on sites you do not own, and follow their terms.

Where do specialist tools still win?

  • Large crawls: dedicated crawlers handle hundreds of thousands of URLs, JavaScript rendering at scale and detailed reporting more efficiently.
  • Backlink and ranking data: these come from SEO platforms' own indexes, which Claude Code cannot recreate.
  • Search Console and analytics data: you need exports or API access; Claude Code can analyse the data once you provide it.
  • AI answer tracking at scale: many engines, locations and runs are easier in a dedicated tracking tool.

A practical split: use specialist tools for data collection at scale, and Claude Code for custom checks, joining datasets, and turning raw findings into a prioritised report.

What does a finished audit output look like?

A good output folder contains:

  • report.md: findings ordered by priority, each with evidence links and a recommended fix;
  • data/: raw fetches, access logs, extracted structured data and log summaries;
  • scripts/: the scripts used, ready to re-run;
  • questions.csv: buyer questions mapped to pages, with gaps marked.

That package is easy to review, hand to a developer, or repeat next quarter.

What do people ask about Claude Code for SEO?

Do I need to be a developer to use Claude Code for audits?

It helps to be comfortable with a terminal and reading simple scripts. You describe the checks in plain language, but you should be able to review what it runs and the files it produces.

Can Claude Code fix SEO issues on my site?

It can edit code in a repository you give it, such as templates, structured data or robots.txt. Review every change and deploy through your normal process, never directly to production.

Is it safe to give Claude Code access to server logs?

Logs can contain personal data such as IP addresses. Remove or mask sensitive fields first, and keep the work on systems you control.

How long does an audit take with Claude Code?

For a site of a few hundred pages, the automated checks usually run in under an hour. Reviewing findings and writing recommendations takes longer and still needs a person.

Published by The Kovmere Team · updated Sep 28, 2026 · More resources