# Restricting npm bypass-2FA granular access tokens

DevFeed: [Restricting npm bypass-2FA granular access tokens](<https://devfeed.tech/articles/restricting-npm-bypass-2fa-granular-access-tokens-71557.md>)

Original publisher: [Read original article](<https://github.blog/changelog/2026-07-31-restricting-npm-bypass-2fa-granular-access-tokens>)

Author: Allison

Published: 2026-07-31T16:45:50Z

Content type: release

Language: en

Sources: [GitHub Changelog](<https://devfeed.tech/sources/github-changelog.md>)

Topics: [npm security](<https://devfeed.tech/topics/npm-security.md>), [npm](<https://devfeed.tech/topics/npm.md>), [credential-based attacks](<https://devfeed.tech/topics/credential-based-attacks.md>), [Secure token management](<https://devfeed.tech/topics/secure-token-management.md>), [account takeover](<https://devfeed.tech/topics/account-takeover.md>), [least privilege](<https://devfeed.tech/topics/least-privilege.md>)

Tags: [2fa](<https://devfeed.tech/tags/2fa.md>), [access-tokens](<https://devfeed.tech/tags/access-tokens.md>), [account](<https://devfeed.tech/tags/account.md>), [attack](<https://devfeed.tech/tags/attack.md>), [automated](<https://devfeed.tech/tags/automated.md>), [bypass](<https://devfeed.tech/tags/bypass.md>), [challenge](<https://devfeed.tech/tags/challenge.md>), [cli](<https://devfeed.tech/tags/cli.md>), [community](<https://devfeed.tech/tags/community.md>), [deprecation](<https://devfeed.tech/tags/deprecation.md>), [github](<https://devfeed.tech/tags/github.md>), [interactive](<https://devfeed.tech/tags/interactive.md>), [maintainers](<https://devfeed.tech/tags/maintainers.md>), [manage](<https://devfeed.tech/tags/manage.md>), [management](<https://devfeed.tech/tags/management.md>), [npm](<https://devfeed.tech/tags/npm.md>), [oidc](<https://devfeed.tech/tags/oidc.md>), [org](<https://devfeed.tech/tags/org.md>), [package](<https://devfeed.tech/tags/package.md>), [package-management](<https://devfeed.tech/tags/package-management.md>)

## AI overview

npm granular access tokens configured to bypass 2FA will no longer be able to manage tokens, package access and maintainers, trusted publishing, or organization and team membership; those actions will require an interactive 2FA challenge. Direct publishing with these tokens will also be removed, leaving private-package reads and staged publishing subject to maintainer approval with 2FA. npm targets January 2027. The change affects npm GATs only, not GitHub personal access tokens, GitHub App tokens, or Actions' `GITHUB_TOKEN`. The excerpt recommends moving automated publishing to trusted publishing (OIDC) or staged publishing.

## Source excerpt

npm granular access tokens (GATs) configured to bypass 2FA can no longer perform sensitive account, org, and package management actions. These now require an interactive 2FA challenge, closing one of...