ScavioScavio
ProductPricingDocs
Sign InGet Started
  1. Home
  2. Tutorials
  3. How to Build a Claude Code SEO Skill
Tutorial

How to Build a Claude Code SEO Skill

Create a Claude Code skill that runs SEO checks with live SERP data. Check rankings, AI Overviews, and keyword gaps from your terminal.

Get Free API KeyAPI Docs

Claude Code skills let you package reusable workflows that Claude Code can invoke on demand. An SEO skill combines live SERP data from the Scavio API with Claude Code's reasoning to run keyword checks, monitor AI Overview visibility, and find content gaps directly in your terminal. This tutorial shows how to create the skill file, configure the MCP server connection, and write the skill instructions that Claude Code follows. You will have a working SEO skill that runs ranking checks, PAA analysis, and AEO monitoring with a single command.

Prerequisites

  • Claude Code CLI installed and configured
  • A Scavio API key from scavio.dev
  • Familiarity with Claude Code skill files and MCP

Walkthrough

Step 1: Create the skill file

Set up the skill directory and create the instruction file for Claude Code.

Python
# Create the skill directory
mkdir -p .claude/skills

# Create the SEO skill file
# .claude/skills/seo.md
# This file contains instructions Claude Code follows
# when the skill is invoked

Step 2: Configure Scavio MCP server

Add the Scavio MCP server to your project so the skill can call search tools.

Python
# .mcp.json in project root:
# {
#   "mcpServers": {
#     "scavio": {
#       "url": "https://mcp.scavio.dev/mcp",
#       "headers": {
#         "x-api-key": "YOUR_SCAVIO_API_KEY"
#       }
#     }
#   }
# }

Step 3: Write skill instructions

Define what the SEO skill does when invoked. The instructions tell Claude Code how to use search data.

Python
# .claude/skills/seo.md content:
# When invoked for a keyword:
# 1. Use scavio search tool to fetch SERP for the keyword
# 2. Report top 5 organic results with positions
# 3. Check if AI Overview exists and list cited domains
# 4. Extract People Also Ask questions
# 5. Identify content gaps compared to top results

Step 4: Test the underlying API

Verify the Scavio API returns the data the skill needs.

Python
import os, requests

API_KEY = os.environ["SCAVIO_API_KEY"]
resp = requests.post("https://api.scavio.dev/api/v1/search",
    headers={"x-api-key": API_KEY},
    json={"platform": "google", "query": "best project management tool"})
data = resp.json()
print(f"Organic: {len(data.get('organic_results', []))}")
print(f"AIO: {'yes' if data.get('ai_overview') else 'no'}")
print(f"PAA: {len(data.get('people_also_ask', []))}")

Step 5: Invoke the skill

Run the skill from your terminal to verify everything is connected.

Python
# In Claude Code terminal:
# /seo "best project management tool"
#
# Claude Code will:
# 1. Call the Scavio MCP search tool
# 2. Parse the SERP response
# 3. Format a report with rankings, AIO, and PAA
# 4. Suggest content improvements

Python Example

Python
import os, requests
API_KEY = os.environ["SCAVIO_API_KEY"]
def seo_check(kw):
    resp = requests.post("https://api.scavio.dev/api/v1/search",
        headers={"x-api-key": API_KEY},
        json={"platform": "google", "query": kw})
    d = resp.json()
    return {"organic": len(d.get("organic_results",[])),
            "aio": bool(d.get("ai_overview")),
            "paa": len(d.get("people_also_ask",[]))}
print(seo_check("best project management tool"))

JavaScript Example

JavaScript
const H = {"x-api-key": process.env.SCAVIO_API_KEY, "Content-Type": "application/json"};
async function seoCheck(kw) {
  const r = await fetch("https://api.scavio.dev/api/v1/search", {
    method: "POST", headers: H,
    body: JSON.stringify({platform: "google", query: kw})
  });
  const d = await r.json();
  return {organic: (d.organic_results||[]).length, aio: !!d.ai_overview,
    paa: (d.people_also_ask||[]).length};
}
seoCheck("best project management tool").then(console.log);

Expected Output

JSON
A Claude Code skill that runs SEO research from the terminal, returning organic rankings, AI Overview status, and People Also Ask questions for any keyword.

Related Tutorials

  • How to Build an SEO Skill for Claude Code
  • How to Add a Search Tool to a Claude Skill

Frequently Asked Questions

Most developers complete this tutorial in 15 to 30 minutes. You will need a Scavio API key (free tier works) and a working Python or JavaScript environment.

Claude Code CLI installed and configured. A Scavio API key from scavio.dev. Familiarity with Claude Code skill files and MCP. A Scavio API key gives you 50 free credits on signup.

Yes. The free tier includes 50 credits on signup, which is more than enough to complete this tutorial and prototype a working solution.

Scavio has a native LangChain package (langchain-scavio), an MCP server, and a plain REST API that works with any HTTP client. This tutorial uses the raw REST API, but you can adapt to your framework of choice.

Related Resources

Best Of

Best SEO Tools for Claude Code in 2026

Read more
Use Case

Claude Code SEO Automation

Read more
Glossary

Claude Code Skill for SEO

Read more
Best Of

Best MCP Search Tools for Claude Code in 2026

Read more
Use Case

Claude Code SEO Content Automation Skill

Read more
Workflow

SEO Keyword Check via Claude MCP Daily

Read more

Start Building

Create a Claude Code skill that runs SEO checks with live SERP data. Check rankings, AI Overviews, and keyword gaps from your terminal.

Get Free API KeyRead the Docs
ScavioScavio

Real-time search API for AI agents. Search every platform, not just Google.

Product

  • Features
  • Pricing
  • Dashboard
  • Affiliates

Developers

  • Documentation
  • API Reference
  • Quickstart
  • MCP Integration
  • Python SDK

Alternatives

  • Tavily Alternative
  • SerpAPI Alternative
  • Firecrawl Alternative
  • Exa Alternative

Tools

  • JSON Formatter
  • cURL to Code
  • Token Counter
  • All Tools

© 2026 Scavio. All rights reserved.

Featured on TAAFT
Terms of ServicePrivacy Policy