internal-linking-optimizer
Analyze site's internal link structure and optimize for hub-and-spoke SEO architecture. Triggers on: "optimize internal links", "internal linking", "link structure", "hub and spoke links", "orphan pages", "link equity", "internal link audit", "fix my internal links", "link architecture", "site structure optimization", "internal linking strategy", "link flow", "improve site structure", "find orphan pages", "maximize link equity", "internal link map".
Best use case
internal-linking-optimizer is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Analyze site's internal link structure and optimize for hub-and-spoke SEO architecture. Triggers on: "optimize internal links", "internal linking", "link structure", "hub and spoke links", "orphan pages", "link equity", "internal link audit", "fix my internal links", "link architecture", "site structure optimization", "internal linking strategy", "link flow", "improve site structure", "find orphan pages", "maximize link equity", "internal link map".
Teams using internal-linking-optimizer should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/internal-linking-optimizer/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How internal-linking-optimizer Compares
| Feature / Agent | internal-linking-optimizer | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Analyze site's internal link structure and optimize for hub-and-spoke SEO architecture. Triggers on: "optimize internal links", "internal linking", "link structure", "hub and spoke links", "orphan pages", "link equity", "internal link audit", "fix my internal links", "link architecture", "site structure optimization", "internal linking strategy", "link flow", "improve site structure", "find orphan pages", "maximize link equity", "internal link map".
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# Internal Linking Optimizer
Analyze your site's internal link structure and generate an optimized hub-and-spoke linking plan. Finds orphan pages (no internal links pointing to them), identifies link equity bottlenecks, and creates specific linking instructions to maximize SEO impact.
## Stage
S6: Analytics & Optimization — This is analytics/audit work on existing content. Internal linking is the most underutilized SEO lever — it's 100% in your control and costs nothing.
## When to Use
- User wants to improve their site's SEO through better internal linking
- User asks about "orphan pages", "link structure", "hub and spoke"
- User says "internal linking", "link audit", "link equity"
- After publishing new content — new pages need internal links within 48 hours
- After `keyword-cluster-architect` — cluster structure defines the ideal link architecture
- Monthly maintenance task alongside `content-decay-detector`
## Input Schema
```yaml
site_url: string # REQUIRED — site to analyze
# e.g., "myblog.com"
pages: object[] # OPTIONAL — known pages with their topics
- url: string
title: string
topic_cluster: string # Which topical cluster it belongs to
is_hub: boolean # Is this a hub page?
hub_pages: string[] # OPTIONAL — URLs of your hub/pillar pages
# Default: auto-detected
new_pages: string[] # OPTIONAL — recently published pages needing links
# Default: none
```
**Chaining from S3 keyword-cluster-architect**: Use `keyword_clusters.hub` and `keyword_clusters.clusters` to define ideal link architecture.
## Workflow
### Step 1: Discover Site Structure
1. `web_search`: `site:[site_url]` — discover indexed pages
2. Map pages to topic clusters (if not provided)
3. Identify current hub pages (pages that link to many others)
4. Note orphan pages (pages with few/no internal links pointing to them)
### Step 2: Analyze Current Link Structure
Read `shared/references/seo-strategy.md` for internal linking rules.
For each page group:
- Count internal links TO this page (inlinks)
- Count internal links FROM this page (outlinks)
- Check link depth from homepage (should be ≤ 3 clicks)
- Identify the anchor text used
### Step 3: Identify Issues
Flag:
1. **Orphan pages** — no or few internal links pointing to them
2. **Hub pages with weak linking** — hub should link to ALL spokes in its cluster
3. **Missing spoke-to-spoke links** — related spokes should link to each other
4. **Broken contextual flow** — pages that should link to each other but don't
5. **Over-linked pages** — too many outlinks dilute link equity
6. **Missing reverse links** — spoke links to hub but hub doesn't link back
### Step 4: Generate Linking Instructions
For each issue, provide specific instructions:
```
Page: [URL]
Action: Add internal link to [target URL]
Anchor text: "[suggested anchor]"
Location: [where in the content to add it]
Priority: [P0/P1/P2]
Reason: [why this link matters]
```
### Step 5: Self-Validation
- [ ] Instructions are specific (exact URLs, anchor text, location)
- [ ] Hub-and-spoke architecture is logical
- [ ] Anchor text is natural and keyword-relevant
- [ ] No recommendations to over-link (max 3-5 internal links per 1000 words)
- [ ] New pages have at least 2-3 internal links pointing to them
## Output Schema
```yaml
output_schema_version: "1.0.0"
internal_links:
site: string
pages_analyzed: number
issues_found: number
links_to_add: number
orphan_pages: string[] # Pages with zero/few inlinks
hub_pages: string[] # Identified hub pages
link_actions:
- source_url: string # Page to add the link ON
target_url: string # Page to link TO
anchor_text: string # Suggested anchor text
location: string # Where in the content
priority: string # "P0" | "P1" | "P2"
reason: string
link_structure: # Current state summary
total_pages: number
avg_inlinks: number
avg_outlinks: number
max_depth: number
chain_metadata:
skill_slug: "internal-linking-optimizer"
stage: "analytics"
timestamp: string
suggested_next:
- "seo-audit"
- "content-decay-detector"
- "affiliate-blog-builder"
```
## Output Format
```
## Internal Link Audit: [Site]
### Structure Overview
- **Pages analyzed:** XX
- **Orphan pages:** XX (need links urgently)
- **Hub pages:** XX
- **Links to add:** XX
- **Average inlinks per page:** X.X
### Orphan Pages (P0 — fix immediately)
These pages have no/few internal links and are invisible to Google:
1. [URL] — [title] — 0 inlinks
2. [URL] — [title] — 1 inlink
### Link Actions
#### P0 — Critical
| Source Page | → | Target Page | Anchor Text | Location |
|---|---|---|---|---|
| [source] | → | [target] | "[anchor]" | After paragraph about [topic] |
#### P1 — High
[same table]
#### P2 — Maintenance
[same table]
### Hub-and-Spoke Health
| Hub Page | Expected Spokes | Linked Spokes | Missing Links |
|---|---|---|---|
| [hub] | XX | XX | [list missing] |
### Quick Wins
1. [Easiest high-impact link to add]
2. [Second easiest]
3. [Third]
```
## Error Handling
- **No site URL**: "I need your site URL to analyze internal links."
- **Site not indexed**: "This site doesn't appear to be indexed. Check robots.txt and sitemap."
- **Too few pages**: "With only [X] pages, focus on creating more content first. Internal linking becomes powerful at 10+ pages."
- **No hub pages identifiable**: "I can't identify clear hub pages. Run `keyword-cluster-architect` first to define your topic structure."
## Examples
**Example 1:** "Audit my blog's internal links"
→ Discover pages, map structure, find orphan pages, generate specific linking instructions with anchor text and placement.
**Example 2:** "I just published a new article, what should I link to it?"
→ Identify 3-5 existing pages that should link to the new article, with specific anchor text and paragraph locations.
**Example 3:** "Optimize internal links based on my keyword clusters" (after keyword-cluster-architect)
→ Use cluster structure to define ideal hub-spoke links. Compare current vs ideal. Generate gap-filling instructions.
## Revenue & Action Plan
### Expected Outcomes
- **Revenue potential**: Internal linking directly increases organic traffic to your money pages (pages with affiliate links). Fixing orphan pages typically increases their organic traffic by 30-100% within 4-6 weeks. If an orphan page earns $100/month, proper linking can push it to $130-200/month
- **Benchmark**: Sites with optimized internal linking rank 20-40% higher for target keywords. Every hub-spoke connection you add is a signal to Google that your content is authoritative
- **Key metric to track**: Organic traffic to money pages (pages containing affiliate links) — measure before and after internal link optimization. Target: 30%+ traffic increase within 6 weeks
### Do This Right Now (15 min)
1. **Fix the top 3 P0 (Critical) links first** — these are orphan money pages getting zero internal link juice
2. Open each source page, find the suggested paragraph, and add the internal link with the recommended anchor text
3. Submit the updated pages to Google Search Console for re-indexing: `Inspect URL → Request Indexing`
4. Set a monthly reminder to re-run this audit
### Track Your Results
After 4 weeks: check Google Search Console for the orphan pages. Did impressions/clicks increase? After 8 weeks: did rankings improve for target keywords? Internal linking compounds — each optimization makes the next one more powerful.
> **Next step — copy-paste this prompt:**
> "Run an SEO audit on my site to find more optimization opportunities" → runs `seo-audit`
## Flywheel Connections
### Feeds Into
- `content-decay-detector` (S3) — pages with weak link structure may be decaying
- `seo-audit` (S6) — link structure is a key SEO factor
- `affiliate-blog-builder` (S3) — new articles need immediate internal links
### Fed By
- `keyword-cluster-architect` (S3) — cluster structure defines ideal link architecture
- `affiliate-blog-builder` (S3) — new content that needs linking
- `seo-audit` (S6) — identifies pages with link structure issues
### Feedback Loop
- `seo-audit` (S6) tracks ranking changes after link optimization → measure impact of internal linking changes
## References
- `shared/references/seo-strategy.md` — Hub-and-spoke linking rules, anchor text rules, link equity flow
- `shared/references/flywheel-connections.md` — Master connection mapRelated Skills
your-skill-name
Replace with when the AI should activate this skill. Be pushy — cover multiple phrasings so the AI activates for a wide range of user prompts.
trending-content-scout
Scan social platforms for top-performing content by engagement before you create anything. Use this skill when the user wants to see what content is winning in a niche, find viral content patterns, research what's working on YouTube/TikTok/X/Reddit, benchmark engagement, discover content gaps, or says "what content is working for [topic]", "show me top performing content about [keyword]", "what's trending in [niche]", "find viral content about [product]", "content research for [keyword]", "what gets views in [niche]", "engagement analysis for [topic]", "scout the competition", "what videos are getting the most views about [keyword]", "social listening for [topic]", "trending content in [niche]", "top content analysis", "what hooks work for [keyword]", "content intelligence", "find winning formats".
traffic-analyzer
Analyze website traffic, global rank, engagement metrics, and traffic sources for any domain. Use this skill to evaluate affiliate program websites, compare competitor traffic, assess advertiser strength, or understand where an audience comes from. Triggers on: "analyze traffic for [domain]", "how much traffic does [site] get", "compare traffic between [site A] and [site B]", "is [program] worth promoting based on traffic", "traffic analysis", "website analytics for [domain]", "where does [site] get traffic", "check if [advertiser] is legit", "evaluate [program] website health", "SimilarWeb analysis", "traffic sources for [domain]", "how popular is [site]", "website rank", "domain authority check", "compare affiliate program websites".
purple-cow-audit
Score product remarkability 1-10 to decide if it's worth promoting. Seth Godin's Purple Cow test. Triggers on: "is this product worth promoting", "should I promote", "product audit", "purple cow", "remarkable product", "is it remarkable", "rate this product", "product quality check", "worth my reputation", "product evaluation", "would I recommend without commission", "product remarkability score", "evaluate this affiliate product", "quality gate for promotion".
niche-opportunity-finder
Find untapped affiliate niches with real earning potential. Use this skill when the user asks about picking a niche, finding a niche to start affiliate marketing, what niche to get into, niche research, niche ideas, beginner niche selection, low competition niches, profitable niches, or says "I don't know what to promote", "help me pick a niche", "what niche should I start with", "find me a niche with less competition", "niche ideas for affiliate", "is X a good niche for affiliate marketing", "best niches 2024", "untapped niches".
monopoly-niche-finder
Find intersection niches where you're the ONLY voice. Thiel's "competition is for losers" lens. Triggers on: "find my monopoly niche", "blue ocean niche", "unique niche", "niche intersection", "where am I the only one", "zero competition niche", "untapped niche", "category of one", "Thiel monopoly", "dominate a niche", "niche nobody else covers", "cross two domains", "find a niche with no competition", "monopoly positioning", "unique angle for affiliate".
list-affitor-program
Research an affiliate program and create a verified listing for list.affitor.com. Use this skill when the user asks anything about listing a program, adding an affiliate program to the directory, submitting a program to list, creating a listing, documenting an affiliate program, sharing an affiliate program, writing a program profile, posting a program to list.affitor.com, or contributing a new program. Also trigger for: "list a program", "add affiliate program", "submit program to list", "create listing for X", "document affiliate program", "share affiliate program", "write a listing", "post to list.affitor.com", "add X to the directory", "register an affiliate program", "publish affiliate program", "new program listing", "profile this affiliate program", "catalog this program".
content-angle-ranker
Rank content angles by engagement data, competition level, and platform fit. Data-driven angle selection instead of guesswork. Use this skill when the user has a keyword or product and needs to decide WHAT to create, which angle to take, which format to use, or which platform to target. Triggers on: "what angle should I use", "rank content ideas for [keyword]", "best angle for [product]", "which content idea will perform best", "help me pick an angle", "what should I write about", "content angle for [topic]", "rank my content ideas", "which approach will get the most views", "data-driven content planning", "angle ranker", "content scoring", "which hook should I use", "compare these content ideas", "prioritize my content angles", "what video should I make".
competitor-spy
Reverse-engineer successful affiliate strategies from competitors. Use this skill when the user asks about spying on competitors, researching what other affiliates promote, analyzing competitor affiliate sites, understanding how top affiliates in a niche make money, or says "what programs does X promote", "how does [site] make money", "what affiliate strategy does this site use", "spy on competitor affiliates", "reverse engineer affiliate site", "copy what works in my niche", "who are the top affiliates in X niche", "what content gets traffic in my niche", "competitor affiliate analysis".
commission-calculator
Calculate realistic affiliate earnings projections before committing to a program. Use this skill when the user asks about affiliate earnings, projecting income, calculating commissions, estimating how much they can make, comparing program payouts, or says "how much can I make promoting X", "calculate my affiliate income", "is this commission worth it", "how long to first $1000", "compare earnings between programs", "traffic to income calculator", "what conversion rate should I expect", "earnings estimate for affiliate program", "how many sales do I need".
affiliate-program-search
Research and evaluate affiliate programs to find the best ones to promote. Use this skill when the user asks anything about finding affiliate programs, comparing commission rates, evaluating affiliate opportunities, searching for products to promote, picking a niche, or mentions list.affitor.com. Also trigger for: "which SaaS should I promote", "best affiliate programs for X", "high commission programs", "recurring commission affiliate", "compare these affiliate programs", "is X affiliate program worth it", "find me something to promote", "what pays the most", "affiliate programs with long cookie duration".
skill-finder
Find the right Affitor skill for your goal. Triggers on: "which skill should I use", "find me a skill", "what skills are available", "help me choose a skill", "skill for SEO", "skill for email", "explore skills", "I'm new to Affitor", "what can Affitor do", "search skills", "skill for blog writing", "skill for landing pages", "skill for analytics".