This page's hreflang points to a French target that is blocked by robots.txt.
/blocked-by-robots/french-targetDisallow: /blocked-by-robots/Hreflang says: "Show French users this French page"
Robots.txt says: "Do not crawl this path"
Search engines cannot use a page they're not allowed to crawl!
Check: hreflang (automatic)
Status: Fail
Severity: Warning
Issue Type: hreflang_target_robots_blocked
Choose one of these solutions:
User-agent: * Disallow: /blocked-by-robots/ # ❌ Blocks the hreflang target
User-agent: * # Allow the French target: Allow: /blocked-by-robots/french-target # ✅ Explicitly allow Disallow: /blocked-by-robots/ # Block other paths
alternates: {
canonical: "https://mock.okok.now/issues/hreflang-target-robots-blocked",
languages: {
en: "https://mock.okok.now/issues/hreflang-target-robots-blocked",
fr: "https://mock.okok.now/blocked-by-robots/french-target", // ❌ Blocked
}
}Never point hreflang to pages blocked by robots.txt.
Search engines need to crawl pages to understand and index them. Blocked pages cannot be used for hreflang targeting.
→ Try visiting the blocked target (may work for users but not crawlers)