robots.txt: scope the /_next/ disallow to Googlebot - #793
Open
danstotts-ops wants to merge 1 commit into
Open
Conversation
PR #785 intended a Googlebot-only rule but wrote it under User-agent: *, so the /_next/ disallows applied to every crawler, including GPTBot, ChatGPT-User, ClaudeBot and Claude Code. Mintlify serves client-side navigation payloads from under /_next/, so agents following those routes were blocked. Adds a Googlebot group carrying the asset disallows, and leaves * with only the shared directives. Content-Signal and Disallow: /cdn-cgi/ are repeated in both groups deliberately: a crawler obeys only its most specific matching group, so Googlebot would otherwise lose them.
Contributor
|
Preview deployment for your docs. Learn more about Mintlify Previews.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Before
The
/_next/and/mintlify-assets/_next/disallows were in theUser-agent: *group. That applied the Mintlify asset restrictions to every crawler, including GPTBot, ChatGPT-User, ClaudeBot, and Claude Code.After
The asset-specific allows and disallows are scoped to a
User-agent: Googlebotgroup. The wildcard group retains only the sharedContent-Signaland/cdn-cgi/directives, so other agents can access Mintlify client-side navigation payloads under/_next/.Content-Signal: ai-train=yes, search=yes, ai-input=yesandDisallow: /cdn-cgi/are deliberately repeated in both groups. A crawler obeys only its most specific matching user-agent group, so Googlebot would lose those directives if they existed only underUser-agent: *.ai-train=yesis intentional Runpod policy for docs.runpod.io. This change does not add any Google-Extended, GPTBot, or other agent-specific block.Verification
robots.txtmatches the requested target byte for byte, including blank lines between groups and beforeSitemap.robots.txt.docs.jsonis unchanged and matchesorigin/mainbyte for byte.git diff --checkpasses.