Module 104 Expert 22 min read

AI in Your SEO Workflow

ChatGPT and Claude for SEO tasks, prompt engineering, AI for keyword research, briefs, technical audits, outreach personalization, and Cursor/Claude Code automation.

By SEO Mastery Editorial

In 2026 the question is not whether to use AI in your SEO workflow. It is which tasks AI does well, which tasks still belong to humans, and where the leverage actually compounds. This module is the operating manual: real prompts, real agent patterns, and the MCP servers that turn an LLM into a junior SEO with shell access.

TL;DR

  • AI does outline, draft scaffolding, classification, and code-shaped tasks well; it does original research, brand voice, and judgment poorly. Use it where the task has structure and verifiable output. Keep humans on the work where ambiguity is the value.
  • Prompt engineering is structured input, not magic incantations. Role, context, examples, output format, constraints, edge cases. Templated and versioned, prompts become assets.
  • Claude Code and Cursor are the highest-leverage SEO tools nobody is calling SEO tools yet. With the right MCP servers and a CLAUDE.md for your repo, an agent can audit your sitemap, validate schema, generate briefs from your style guide, and ship template changes through a PR.

The mental model

Working with AI in SEO is like managing a fleet of brilliant but unreliable junior associates. They have read every SEO blog ever published, can produce draft work in seconds, and will miss subtle context constantly. They are infinite-bandwidth but require checking; that ratio is the entire trick.

A senior associate’s job is to set the brief tightly, check the output critically, and use the time saved to do the work that requires actual judgment. The same shape applies here. Your job is to specify the task, supply the context, validate the result, and reinvest the saved hours in things AI cannot do — strategy, relationships, original research, brand voice, judgment calls on YMYL.

The trap is treating AI as a 1.0 productivity multiplier. It is not; it is a selective multiplier. On the right tasks (outline generation, classification, content-gap analysis, draft schema, brief structuring, internal-linking suggestions), 5–10×. On the wrong tasks (trustworthy research, brand voice, novel claims, controversial calls), it actively hurts. The whole skill is selection.

Deep dive: the 2026 reality

The model landscape as of Q1 2026:

ModelBest for SEO workNotable feature
Claude Opus 4.7 (1M context)Deep audits, long-doc analysis, careful reasoning1M token context handles full sitemaps, large code reviews
Claude Sonnet 4.5Day-to-day SEO tasks, balanced costFast, cheap, strong at structured output
GPT-5Reasoning, code, multi-step planningOpenAI’s reasoning mode handles ambiguity well
GPT-4.5 TurboVolume work, classificationsCheap and fast
Gemini 2.5 ProMultimodal, when working inside Google ecosystemNative integration with Search Console data via Workspace
Llama 3.3 / Mistral / local modelsSensitive data work, cost-controlled volumeRun on-prem if privacy is a constraint

The pricing differentiator: heavy-volume classification work runs cheaper on Sonnet 4.5 or GPT-4.5 Turbo; deep one-shot audits run better on Opus 4.7 or GPT-5. Match model to task.

Where AI earns its keep

TaskWhy AI does this wellTime saved
Cluster SERP analysisPattern recognition across 10–50 SERPs60–80%
Content brief generationTemplated structure, variable inputs70%
Schema generationJSON-LD is structured, errors are detectable80%
Internal-link suggestionEmbedding similarity at scale80%
Title and meta variantsGenerate 20, pick 350–60%
Outreach personalizationVariable substitution against research70%
Technical audit summarizationReduce 2,000 issues to a 12-item action list60%
Content outline from research notesSynthesis of structured input70%
Translation draftingLinguistic competence at scale50%
Content refresh diffIdentify stale facts in old articles60%

Where AI fails

TaskWhy it failsWhat humans still own
YMYL content productionHallucinated facts kill trust; QRG penaltyCredentialed authoring, citation validation
Brand voiceDrifts toward generic “helpful AI assistant” toneStyle guide enforcement, editorial review
Original researchCannot interview, observe, or testField work, surveys, primary data
Strategy callsOptimizes locally; misses positioningPositioning, prioritization, trade-offs
Trust-establishing content”Why we exist,” methodology, missionFounder voice, leadership perspective
Controversial takesHedges by trainingEditorial point of view

Prompt engineering structure

A working SEO prompt has six components:

ComponentExample
Role”You are a senior technical SEO with 12 years of experience auditing e-commerce sites.”
Context”We run a Shopify store with 4,200 product pages and 180 category pages. Our priority is improving CTR from existing rankings, not gaining new ones.”
Task”Analyze the following 30 title tags. Identify the bottom 10 by likely CTR.”
Examples”A high-CTR title for this audience looks like ‘$THING — Shipped in 24 Hours - $BRAND’ (specifics, urgency, brand).”
Output format”Return a Markdown table with columns: rank, current title, weakness, proposed rewrite.”
Constraints”Each rewrite must be 50–60 characters. Never use exclamation marks. Brand goes last.”

A prompt missing any of these produces variance. Prompts including all six produce reliable output.

Working prompt: SERP-cluster intent analysis

Role: You are a senior content strategist with deep experience in
SERP analysis for B2B SaaS.

Context: We rank #18 for "marketing automation for small business."
Our page is at example.com/marketing-automation-smb. We have not
ranked top 10 for the past 9 months. The SERP has shifted from
informational toward comparison-style results.

Task: Analyze the following 10 ranking results and identify the
dominant intent, the format the SERP rewards, and the gap between
the SERP shape and our current page.

Input:
1. https://hubspot.com/... — title: "Marketing Automation for SMBs..." 
   intro snippet: "..."
[ten SERPs with title, URL, meta description, top H2s]

Examples of useful gap analysis:
- "9 of 10 results have a comparison table; we have prose." 
- "Average word count is 2,800; ours is 1,400." 
- "All top results include screenshots; ours has none."

Output format: 
- Dominant intent: one sentence
- SERP format pattern: bulleted list of 3-5 patterns
- Our page gap: bulleted list, prioritized by likely impact
- Recommended action: numbered list of 5 specific changes

Constraints: Be specific. No generic advice like "improve quality."
Cite specific competitors as evidence for each claim.

This prompt format produces auditable output. Run it across a hundred queries and you have a content roadmap.

Agent patterns: Claude Code and Cursor for SEO

Claude Code is the agent runtime for Anthropic models with shell access. Cursor is a code editor with an integrated agent. Both shine for SEO work where the task involves files, repos, or APIs.

Three agent patterns that earn their keep:

Pattern 1: The audit agent. Point Claude Code at a directory and ask for a structured audit. With Screaming Frog CSV exports in the directory, the agent can produce the same kind of analysis a senior SEO would, in minutes.

Pattern 2: The schema agent. Provide a page template and JSON-LD schema requirements. The agent generates the JSON-LD, validates it via the Schema MCP server, and returns the diff to apply.

Pattern 3: The brief agent. Given a target query, a SERP export, and your house style guide, the agent produces a brief that follows your team’s exact format.

MCP servers that matter for SEO

The Model Context Protocol is the open standard (introduced by Anthropic in November 2024) that lets agents connect to tools. By Q1 2026 there is a real ecosystem.

MCP ServerWhat it gives the agent
GitHubRead/write repos, open PRs, comment on PRs
Google Search ConsoleQuery performance data, index inspection
Bing Webmaster ToolsBing performance, IndexNow submission
Ahrefs / Semrush (third-party MCP wrappers)Keyword and backlink data
Screaming Frog (CLI MCP)Trigger crawls and read CSV outputs
PageSpeed InsightsLighthouse scores via API
Schema.org ValidatorJSON-LD validation
FilesystemRead/write files in a project
Postgres / BigQueryDirect query against your warehouse
Linear / JiraRead/write tickets
SlackNotify and respond to threads
Web fetchPull a URL into context
Vercel / CloudflareRead edge logs, deployment state

Configure these in your ~/.config/Claude/mcp.json (or Cursor’s equivalent) and the agent gains hands. A daily SEO standup the agent can run unattended:

  1. Pull yesterday’s GSC anomalies via the GSC MCP.
  2. Cross-reference with the Vercel deployment log.
  3. Run a Screaming Frog crawl on any pages with a >20% impression drop.
  4. Open a Linear ticket per confirmed regression.
  5. Post a Slack summary in #seo.

CLAUDE.md for your SEO repo

Put a CLAUDE.md at the root of your repo. The agent reads it on every session and follows the conventions inside. A working version:

# Project: example.com

## Stack
- Next.js 15 App Router, TypeScript
- Hosted on Vercel
- Sanity CMS for content

## SEO conventions
- Canonical URLs go in `app/[...slug]/page.tsx` via `generateMetadata`
- JSON-LD via `<Script type="application/ld+json">` in the page
  component, never the layout
- Sitemap is generated from `app/sitemap.ts`; never write a static
  `public/sitemap.xml`
- robots.txt generated from `app/robots.ts`; AI crawler rules are at
  the bottom of the file
- All URL slugs lowercase, hyphenated, no trailing slash

## When opening a PR
- Always run `pnpm lint` and `pnpm test` first
- Title format: "[seo] short imperative description"
- Include a "Test URLs" section in the PR body listing 3+ pages to
  verify

## Commands
- pnpm dev — local dev
- pnpm build — production build
- pnpm crawl — run the local Screaming Frog headless config
- pnpm validate-schema — validate all JSON-LD against schema.org

## Tone for content
- Direct, specific, no marketing fluff
- Always cite sources for any claim about a third party
- YMYL pages require credentialed author and reviewer fields

With this in place, the agent stops asking obvious questions and stops making framework-appropriate but project-inappropriate choices.

Visualizing it

flowchart TD
  A["SEO request"] --> B{"Task type"}
  B -->|"Original research"| C["Human only"]
  B -->|"Brand voice content"| C
  B -->|"YMYL critical claim"| C
  B -->|"Strategy call"| C
  B -->|"Structured task"| D["AI-assisted path"]
  D --> E["Pick model"]
  E -->|"Volume / classification"| F["Sonnet or GPT-4.5"]
  E -->|"Deep audit / long context"| G["Opus 4.7 1M"]
  F --> H["Build prompt with 6 components"]
  G --> H
  H --> I["Run via API or agent"]
  I --> J["Validate output"]
  J --> K{"Pass"}
  K -->|"No"| L["Refine prompt or escalate to human"]
  K -->|"Yes"| M["Ship"]
  L --> H
  M --> N["Log prompt and output for prompt library"]

Bad vs. expert

The bad approach

ChatGPT prompt: "Write a 2000 word blog post about marketing automation
for small businesses. Make it SEO optimized."

Result pasted into CMS, published.

This produces generic, hallucinated, voice-mismatched content with fabricated statistics and no first-hand experience. It triggers HCU/scaled-content-abuse signals. It will be rated Low by quality raters. It misses E-E-A-T entirely. The team has saved an hour and bought months of recovery work.

The expert approach

# brief-agent.py — produce a publishable brief, not draft content
import anthropic
import json

client = anthropic.Anthropic()

SYSTEM = """You are a senior content strategist on the example.com team.
You produce briefs, not drafts. Your output is a Markdown brief that a
human writer with subject-matter expertise will use to draft the article.

You always include:
- Target query and dominant intent
- Working title (50-60 chars)
- Meta description (140-160 chars)  
- Required H2/H3 structure derived from SERP analysis
- Internal-link plan (3-7 links to existing /pages we have)
- Schema requirements with the exact JSON-LD type
- 3-5 questions the human writer must answer with first-hand evidence
- 3-5 sources the writer should consult (no generic 'industry sources')

You never produce the body content itself."""

def make_brief(target_query: str, serp_data: list[dict],
               internal_pages: list[str]) -> str:
    prompt = f"""Target query: {target_query}

SERP analysis (top 10):
{json.dumps(serp_data, indent=2)}

Existing pages we can internal-link from:
{json.dumps(internal_pages, indent=2)}

Produce the brief."""

    msg = client.messages.create(
        model="claude-sonnet-4-5",
        max_tokens=4000,
        system=SYSTEM,
        messages=[{"role": "user", "content": prompt}],
    )
    return msg.content[0].text

# Output goes through human review before any drafting starts.

This works because AI does what AI does well — synthesize patterns from structured input — and stops at the boundary where human judgment is required. The writer then drafts with first-hand evidence, original photography, and named expertise, satisfying both QRG and HCU signals. Output volume goes up; output quality stays human-grade.

Do this today

  1. Subscribe to Claude Pro ($20/mo) and ChatGPT Plus ($20/mo) for at least one operator on your team. Compare on the same five SEO prompts for a week; pick the one that matches your work better.
  2. Install Claude Code and Cursor. Configure each with your repo open. Add a starter CLAUDE.md (and .cursor/rules) describing your stack, conventions, and SEO rules.
  3. Build a prompt library in Notion or GitHub. Start with 10 templates: SERP analysis, brief generation, schema validation, content refresh diff, internal-link suggestion, title rewrite, meta description batch, classification, audit summary, outreach personalization.
  4. Configure these MCP servers: GitHub, filesystem, web fetch, Schema validator, GSC (or Search Console API wrapper). Test each by asking the agent to read or write something concrete.
  5. Run a 2-hour pair session with your team: one operator drives Claude Code, the rest watch and critique. Build the team’s intuition for what the agent does well and where it needs supervision.
  6. Pick one weekly recurring task — for example, the Monday traffic-anomaly review. Convert it into an agent run with logged inputs and outputs. After 4 weeks, evaluate whether the agent run replaces or augments the human task.
  7. For content briefs, deploy the brief agent pattern from this module. Track the human-edit ratio (how much of the AI output survives the human review). Tune the prompt until the ratio is above 70%.
  8. For technical audits, feed Screaming Frog export CSVs into Claude Opus and ask for prioritized issues with severity scoring. Compare the output to your own analysis on a known-good audit; iterate until they converge.
  9. Establish a never-publish-AI-without-edit rule. Every piece of AI-generated content gets an author byline only after a credentialed human has revised it materially and added first-hand evidence.
  10. Track ROI explicitly. In your sprint retro, log “what AI shipped” — number of briefs, audits, schema generations, outreach personalizations. After a quarter, you will know whether the workflow is paying off and where to invest more.

Mark complete

Toggle to remember this module as mastered. Saved to your browser only.

More in this part

Part 14: Tools & Workflow

View all on the home page →
  1. 101 The Complete SEO Tool Stack 15m
  2. 102 SEO Workflows & Project Management 12m
  3. 103 Working with Developers 20m
  4. 104 AI in Your SEO Workflow You're here 22m