core(robots-txt): add License directive - #17160
Open
rafeblandford wants to merge 1 commit into
Open
Conversation
rafeblandford
requested review from
connorjclark
and removed request for
a team
August 7, 2026 21:33
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.
Summary
RSL (Really Simple Licensing) 1.0 defines a
Licenserobots.txt directive, which points crawlers at a machine-readable licensing document describing how a site's content may be used. RSL explicitly extends RFC 9309, and an RSL-compliantrobots.txtis required to carry one or moreLicensedirectives — but Lighthouse currently flags it as an "Unknown directive", so a site that adopts the standard loses therobots-txtaudit and roughly 8% of its SEO category score for doing so.Google's own parser does not treat it as an error. Per Google's robots.txt documentation: "Rules other than
allow,disallow, anduser-agentare ignored by the robots.txt parser", and "Google ignores invalid lines in robots.txt files." An unrecognised directive invalidates neither the file nor the group.This PR adds
licenseto the robots.txt safelist and extends the existing valid-robots.txt test to cover it. Same shape and rationale as #16767, which addedContent-Signalto the same list under the "not officially supported, but used in the wild" comment.Resources:
Licensedirective)Related Issues/PRs
Content-Signaldirective #16767 — addedContent-Signalto the same safelist