From 1 February 2027, GitHub rejects OAuth callback URLs that contain a # fragment
GitHub will block OAuth and GitHub App sign-ins whose redirect URI has a URL fragment from 1 Feb 2027. Affected apps must remove the fragment now.

TL;DR
- Starting 1 February 2027, GitHub will reject OAuth authorization requests whose redirect URI contains a URL fragment [1].
- GitHub says fragments are not part of the OAuth 2.0 spec and can be used to intercept an authorization code or token [1].
- Until then, affected apps show a warning in settings and users see a caution message at sign-in; GitHub Enterprise Server is not affected [1].
GitHub will start rejecting OAuth authorization requests that use a redirect URI containing a URL fragment on 1 February 2027, the company announced on 30 November 2026 [1]. Any GitHub App or OAuth app that registers a callback URL with a # fragment is affected, and GitHub asks developers to remove the fragment now to avoid disruption [1].
Why GitHub is doing this
GitHub says redirect URIs with fragments are not part of the OAuth 2.0 specification, citing RFC 6749 section 3.1.2.3 [1]. It also calls them a security risk, because a fragment can be used to intercept an authorization code or token during the redirect [1].
For teams that build “Sign in with GitHub”, internal developer tools or CI integrations on GitHub Apps, this is a hard deadline: once enforcement starts, a callback URL with a fragment cannot be registered or used [1].
What changes and when
Until 1 February 2027, GitHub shows a warning in the settings of an affected app, and users who sign in through that app see a caution message [1]. After that date, sign-ins through such a URL fail [2]. GitHub’s documentation gives https://example.com/callback#section as an example of a URL that will be rejected, and says fragments must be removed from both the registered callback URLs and any redirect_uri values an app sends [2][3].
The change covers github.com on the Free, Team and Enterprise Cloud plans; it does not apply to GitHub Enterprise Server [1].
Related settings worth checking
A GitHub App can register up to 10 callback URLs; when an app does not send redirect_uri, GitHub uses the first callback URL [2]. OAuth apps also fall back to the first configured callback URL when redirect_uri is left out [3].
GitHub’s docs also note that apps which had a single callback URL before 3 August 2026 have wildcard matching turned on for it, which lets any subdomain or subdirectory of that URL receive authorization codes [2]. GitHub warns this can expose an app to attackers and recommends turning wildcard matching off if the app does not need it [2].
What builders can do now
- Open the settings of each GitHub App and OAuth app you own and look for the new warning or any callback URL with a
#[1]. - Remove the fragment from registered callback URLs and from the
redirect_uriyour code sends before 1 February 2027 [2]. - While there, turn off wildcard matching on callback URLs that do not need it [2].
Sources
Written and checked by AI from the sources below
- Deprecating redirect URI fragments for OAuth and GitHub Apps
- About the user authorization callback URL
- Authorizing OAuth apps
Fact-checked by gpt-6.1-sol on · Editorial policy



