seo-hreflang
Skill4 starsChanged 9 months agoMITView on GitHub
Hreflang and international SEO audit, validation, and generation. Detects common mistakes, validates language/region codes, and generates correct hreflang implementations. Use when user says "hreflang", "i18n SEO", "international SEO", "multi-language", "multi-region", or "language tags".
25 other projects use a version of this, 13 of them edited.
Adopted by
Most recently taken up by
- joaoguirunas/team-osedited, first seen Sep 26, 2026
- avalonreset/legends-seo-dungeonedited, first seen Sep 6, 2026
- gaznil/seo-skills-by-gazniledited, first seen Aug 31, 2026
- Haniubub/seo-toolkitedited, first seen Aug 29, 2026
- asale-ai/seo-geo-skilledited, first seen Aug 29, 2026
- Yass5002/agent-skillsedited, first seen Aug 27, 2026
Used with
Projects with it also use seo-google, seo-sxo and 8 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
amirjahfar1Skillseo-google
Direct access to Google's own SEO data via Search Console (Search Analytics, URL Inspection, Sitemaps), PageSpeed Insights v5, CrUX field data with 25-week history, Indexing API v3, GA4 organic traffic, YouTube video search, Google NLP entity/sentiment analysis, Knowledge Graph entity verification, Web Risk safety, and Google Ads Keyword Planner. Bridges crawl-based analysis (the rest of this catalogue) with Google's real-time field data — actual Chrome user metrics, real indexation status, real search performance, real organic traffic. Use when the user asks "search console", "GSC", "PageSpeed", "CrUX", "field data", "indexing API", "GA4 organic", "URL inspection", "google api setup", "real CWV data", "impressions", "clicks", "CTR", "position data", "LCP", "INP", "CLS", "FCP", "TTFB", "Lighthouse scores", "youtube SEO", "knowledge graph", "keyword planner", or "real google data".
Also in 11 projects that use this
amirjahfar1Skillseo-sxo
Diagnose why a page is not ranking by reading the SERP backwards. Identifies the page type Google rewards for the target keyword, scores the candidate page against that pattern from multiple persona perspectives, and recommends the page format that would win the SERP. Use when the user asks "why isn't this page ranking", "page type mismatch", "SXO", "search experience optimization", "intent mismatch", or wants a wireframe.
Also in 11 projects that use this
AgriciDanielSkillseo-image-gen
AI image generation for SEO assets: OG/social preview images, blog hero images, schema images, product photography, infographics. Powered by Gemini via nanobanana-mcp. Requires banana extension installed. Use when user says \"generate image\", \"OG image\", \"social preview\", \"hero image\", \"blog image\", \"product photo\", \"infographic\", \"seo image\", \"create visual\", \"image-gen\", \"favicon\", \"schema image\", \"pinterest pin\", \"generate visual\", \"banner\", or \"thumbnail\".
Also in 10 projects that use this
mvstepanekSkillseo-ecommerce
E-commerce specific SEO rules for product pages, category pages, pricing, availability, faceted navigation, and B2B considerations. Use when building or modifying product listings, category pages, shopping cart, or checkout.
Also in 10 projects that use this
AgriciDanielSkillseo-flow
FLOW framework integration: evidence-led SEO using the Find → Leverage → Optimize → Win loop. Surfaces stage-specific AI prompts from the FLOW knowledge base (41 prompts, CC BY 4.0). Use when user says "FLOW", "FLOW framework", "seo flow", "evidence-led SEO", "find leverage optimize win", or wants stage-specific SEO prompts.
Also in 8 projects that use this
indranilbanerjeeSkillseo-drift
Compare two SEO snapshots from the same source — GSC, the GSC AI Performance report, a rank-tracker export, or aeo-audit probes — into a drift report: top gainers and losers per metric, growth/decline/reshuffle/stable/new/lost classification, and a four-gate quality scorecard. Triggers on \"/digital-marketing-pro:seo-drift\", \"compare this month's GSC export to last month's\", \"what moved after the core update\", \"did the content refresh work\", \"which queries lost AI Mode impressions\". Runs scripts/seo_drift.py on two CSVs, reads the brand profile for noise thresholds, and branches findings to /digital-marketing-pro:seo-audit, /digital-marketing-pro:aeo-geo, or /digital-marketing-pro:content-engine.
Also in 11 projects that use this
- +1 more from amirjahfar1
- +3 more from AgriciDaniel
Other versions25 projects use a version of this.
Word for word · 5
- coopersimson96/ai-content-system★ 17100% same
- megastep/codex-skills★ 7100% same
- realwigu/claude-skills★ 4100% same
- get-proofpilot/claude-skills-catalog★ 1100% same
- royaluniondesign-sys/claude-os★ 1100% same
Edited · 13
- AgriciDaniel/claude-seo★ 18k52% same
- Haniubub/seo-toolkit★ 758% same
- asale-ai/seo-geo-skill★ 653% same
- mikiarlo3/enso-SEO-GEO★ 658% same
- joaoguirunas/team-os★ 352% same
- avalonreset/legends-seo-dungeon★ 257% same
- unknownking07/claude-skills★ 292% same
- agrivisionai/claude-skills★ 169% same
- mahiunfiltered/claude-code-skills★ 169% same
- Biznomad/claude-skills★ 069% same
3 more not listed
Wrote their own version · 7
- seranking/seo-skills★ 155same name
- seoskillsai/seo-skills-ai★ 18same name
- ZachArticulateV/designer-pro-and-seo★ 9same name
- amirjahfar1/automate-seo-with-claude★ 2same name
- oegeyilmaz9/seo-aeo-geo-ultimate★ 2same name
- mvstepanek/nextjs-ecommerce-seo-skills★ 1same name
- FreeAutomation-Tech/claude-seo-kit★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository25 other files it gives its agents.
- seo-agentSkill
- seo-auditSkill
- seo-backlinksSkill
- seo-competitor-analysisSkill
- seo-competitor-pagesSkill
- seo-content-briefSkill
- seo-contentSkill
- seo-data-toolsSkill
- seo-geoSkill
- seo-imagesSkill
- seo-keyword-researchSkill
- seo-localSkill
- seo-monitorSkill
- seo-multiplatformSkill
- seo-pageSkill
- seo-performanceSkill
- seo-planSkill
- seo-programmaticSkill
- seo-rank-trackerSkill
- seo-reportSkill
- seo-schemaSkill
- seo-sitemapSkill
- seoSkill
- seo-technicalSkill
- seo-visualSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
15 rules. 10 are common, 1 is distinctive, and 4 are very specific to this project.
10
Common
Most of the 20 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Common: line 19
Every page must include an hreflang tag pointing to itself
- Common: line 24
If page A links to page B with hreflang, page B must link back to page A
- Common: line 25
Every hreflang relationship must be bidirectional (A→B and B→A)
- Common: line 27
Check all language versions reference each other (full mesh)
- Common: line 32
Only one x-default per set of alternates
- Common: line 33
Must also have return tags from all other language versions
- Very specific: line 36
Must use ISO 639-1 two-letter codes (e.g., en, fr, de, ja)
- Very specific: line 52
If a page has rel=canonical pointing elsewhere, hreflang on that page is ignored
- Common: line 57
All URLs in an hreflang set must use the same protocol (HTTPS or HTTP)
- Common: line 59
After HTTPS migration, update all hreflang tags to HTTPS
- Distinctive: line 64
Verify both domains are verified in Google Search Console
- Very specific: line 94
Place in <head> section. Every page must include all alternates including itself.
- Common: line 124
Validate language codes: Verify all codes against ISO 639-1 and ISO 3166-1
- Common: line 125
Generate tags: Create hreflang tags for each page including self-referencing
- Very specific: line 156
Every <url> entry must include ALL language alternates (including itself)
“Common” is measured: kept by at least 6 in 10 of the 20 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Hreflang & International SEO
Validate existing hreflang implementations or generate correct hreflang tags for multi-language and multi-region sites. Supports HTML, HTTP header, and XML sitemap implementations.
Validation Checks
1. Self-Referencing Tags
- Every page must include an hreflang tag pointing to itself
- The self-referencing URL must exactly match the page's canonical URL
- Missing self-referencing tags cause Google to ignore the entire hreflang set
2. Return Tags
- If page A links to page B with hreflang, page B must link back to page A
- Every hreflang relationship must be bidirectional (A→B and B→A)
- Missing return tags invalidate the hreflang signal for both pages
- Check all language versions reference each other (full mesh)
3. x-default Tag
- Required: designates the fallback page for unmatched languages/regions
- Typically points to the language selector page or English version
- Only one x-default per set of alternates
- Must also have return tags from all other language versions
4. Language Code Validation
- Must use ISO 639-1 two-letter codes (e.g.,
en,fr,de,ja) - Common errors:
enginstead ofen(ISO 639-2, not valid for hreflang)jpinstead ofja(incorrect code for Japanese)zhwithout region qualifier (ambiguous — usezh-Hansorzh-Hant)
5. Region Code Validation
- Optional region qualifier uses ISO 3166-1 Alpha-2 (e.g.,
en-US,en-GB,pt-BR) - Format:
language-REGION(lowercase language, uppercase region) - Common errors:
en-ukinstead ofen-GB(UK is not a valid ISO 3166-1 code)es-LA(Latin America is not a country — use specific countries)- Region without language prefix
6. Canonical URL Alignment
- Hreflang tags must only appear on canonical URLs
- If a page has
rel=canonicalpointing elsewhere, hreflang on that page is ignored - The canonical URL and hreflang URL must match exactly (including trailing slashes)
- Non-canonical pages should not be in any hreflang set
7. Protocol Consistency
- All URLs in an hreflang set must use the same protocol (HTTPS or HTTP)
- Mixed HTTP/HTTPS in hreflang sets causes validation failures
- After HTTPS migration, update all hreflang tags to HTTPS
8. Cross-Domain Support
- Hreflang works across different domains (e.g., example.com and example.de)
- Cross-domain hreflang requires return tags on both domains
- Verify both domains are verified in Google Search Console
- Sitemap-based implementation recommended for cross-domain setups
Common Mistakes
| Issue | Severity | Fix |
| Missing self-referencing tag | Critical | Add hreflang pointing to same page URL |
| Missing return tags (A→B but no B→A) | Critical | Add matching return tags on all alternates |
| Missing x-default | High | Add x-default pointing to fallback/selector page |
Invalid language code (e.g., eng) | High | Use ISO 639-1 two-letter codes |
Invalid region code (e.g., en-uk) | High | Use ISO 3166-1 Alpha-2 codes |
| Hreflang on non-canonical URL | High | Move hreflang to canonical URL only |
| HTTP/HTTPS mismatch in URLs | Medium | Standardize all URLs to HTTPS |
| Trailing slash inconsistency | Medium | Match canonical URL format exactly |
| Hreflang in both HTML and sitemap | Low | Choose one method — sitemap preferred for large sites |
| Language without region when needed | Low | Add region qualifier for geo-targeted content |
Implementation Methods
Method 1: HTML Link Tags
Best for: Sites with <50 language/region variants per page.
<link rel="alternate" hreflang="en-US" href="https://example.com/page" />
<link rel="alternate" hreflang="en-GB" href="https://example.co.uk/page" />
<link rel="alternate" hreflang="fr" href="https://example.com/fr/page" />
<link rel="alternate" hreflang="x-default" href="https://example.com/page" />Place in <head> section. Every page must include all alternates including itself.
Method 2: HTTP Headers
Best for: Non-HTML files (PDFs, documents).
Link: <https://example.com/page>; rel="alternate"; hreflang="en-US",
<https://example.com/fr/page>; rel="alternate"; hreflang="fr",
<https://example.com/page>; rel="alternate"; hreflang="x-default"Set via server configuration or CDN rules.
Method 3: XML Sitemap (Recommended for large sites)
Best for: Sites with many language variants, cross-domain setups, or 50+ pages.
See Hreflang Sitemap Generation section below.
Method Comparison
| Method | Best For | Pros | Cons |
| HTML link tags | Small sites (<50 variants) | Easy to implement, visible in source | Bloats <head>, hard to maintain at scale |
| HTTP headers | Non-HTML files | Works for PDFs, images | Complex server config, not visible in HTML |
| XML sitemap | Large sites, cross-domain | Scalable, centralized management | Not visible on page, requires sitemap maintenance |
Hreflang Generation
Process
- Detect languages: Scan site for language indicators (URL path, subdomain, TLD, HTML lang attribute)
- Map page equivalents: Match corresponding pages across languages/regions
- Validate language codes: Verify all codes against ISO 639-1 and ISO 3166-1
- Generate tags: Create hreflang tags for each page including self-referencing
- Verify return tags: Confirm all relationships are bidirectional
- Add x-default: Set fallback for each page set
- Output: Generate implementation code (HTML, HTTP headers, or sitemap XML)
Hreflang Sitemap Generation
Sitemap with Hreflang
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
xmlns:xhtml="http://www.w3.org/1999/xhtml">
<url>
<loc>https://example.com/page</loc>
<xhtml:link rel="alternate" hreflang="en-US" href="https://example.com/page" />
<xhtml:link rel="alternate" hreflang="fr" href="https://example.com/fr/page" />
<xhtml:link rel="alternate" hreflang="de" href="https://example.de/page" />
<xhtml:link rel="alternate" hreflang="x-default" href="https://example.com/page" />
</url>
<url>
<loc>https://example.com/fr/page</loc>
<xhtml:link rel="alternate" hreflang="en-US" href="https://example.com/page" />
<xhtml:link rel="alternate" hreflang="fr" href="https://example.com/fr/page" />
<xhtml:link rel="alternate" hreflang="de" href="https://example.de/page" />
<xhtml:link rel="alternate" hreflang="x-default" href="https://example.com/page" />
</url>
</urlset>Key rules:
- Include the
xmlns:xhtmlnamespace declaration - Every
<url>entry must include ALL language alternates (including itself) - Each alternate must appear as a separate
<url>entry with its own full set - Split at 50,000 URLs per sitemap file
Output
Hreflang Validation Report
Summary
- Total pages scanned: XX
- Language variants detected: XX
- Issues found: XX (Critical: X, High: X, Medium: X, Low: X)
Validation Results
| Language | URL | Self-Ref | Return Tags | x-default | Status |
| en-US | https://... | ✅ | ✅ | ✅ | ✅ |
| fr | https://... | ❌ | ⚠️ | ✅ | ❌ |
| de | https://... | ✅ | ❌ | ✅ | ❌ |
Generated Hreflang Tags
- HTML
<link>tags (if HTML method chosen) - HTTP header values (if header method chosen)
hreflang-sitemap.xml(if sitemap method chosen)
Recommendations
- Missing implementations to add
- Incorrect codes to fix
- Method migration suggestions (e.g., HTML → sitemap for scale)
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

