diff --git a/netlify.toml b/netlify.toml index 3eae5bbef..8d22c498f 100644 --- a/netlify.toml +++ b/netlify.toml @@ -3,6 +3,18 @@ [headers.values] Link = "; rel=\"service-doc\"" +# Keep archived documentation versions out of search engines. +# The current docs live at /docs/... (no version segment) and stay indexed; +# every numbered snapshot at /docs/1.XX/ is de-indexed. The trailing splat means +# new versions are covered automatically, with no per-release change needed. +# Note: we intentionally do NOT Disallow these in robots.txt. A crawler must be +# allowed to fetch the page to see this header, and "follow" lets link equity +# still flow to the current docs. +[[headers]] + for = "/docs/1.*" + [headers.values] + X-Robots-Tag = "noindex, follow" + [[redirects]] from = "/*/index.html" to = "/:splat/"