What npm changed on October 2
GitHub has spent the second half of 2026 narrowing the ways a package can reach the npm registry. The newest step came on October 2, 2026: trusted publishing configurations that have not been used now expire 48 hours after creation and can no longer authorize a publish. A configuration becomes validated, and exempt from expiry, after its first successful publish. Changing the repository or project identity creates a new trust relationship with a fresh 48-hour window, while ordinary edits do not reset the clock. Expired configurations stay visible in the package settings, and other valid configurations on the same package keep working. GitHub gives the reason as limiting the risk of trusting a repository or project name that later changes ownership.
The same entry blocks trusted publishing tokens from GitHub Actions workflows triggered by issue_comment, in addition to the existing block on pull_request_target. A workflow that publishes when someone comments on an issue or pull request has to move to push, release or workflow_dispatch.
Stage-only tokens and staged publishing for new packages
On September 18 npm added a “Read and write (stage only)” permission for granular access tokens. The workflow runs npm stage publish, and a maintainer reviews the staged version and approves it with two-factor authentication. With a stage-only token, npm publish is rejected even when the token is set to bypass 2FA. The token keeps other write permissions, such as changing dist-tags and deprecating versions, so GitHub says to protect it like any other write token. It needs npm CLI 11.15.0 or later, Node.js 22.14.0 or later and 2FA on the account. The option is opt-in, and existing tokens keep their current rights until npm changes them.
A second entry on October 2 let staged publishing create a brand new package. That covers public scoped, public unscoped and private scoped packages. The first version lands in the staged queue, and nobody can install it until a maintainer promotes it. Before this, a team using staged publishing still needed a manual first publish.
The January 2027 target for 2FA-bypass tokens
These changes point at one date. A July 8 changelog entry set out a two-stage phase-out of granular tokens that bypass 2FA, and the July 31 entry confirmed the first stage. Those tokens can no longer create or delete tokens, change package access, maintainers or trusted publishing settings, or manage organization membership without an interactive 2FA challenge. The second stage, which GitHub describes as targeted for January 2027, removes their direct publish rights. They will still be able to read private packages and stage a publish for human approval. GitHub personal access tokens, GitHub App tokens and GITHUB_TOKEN in Actions are not part of this change.
The July 8 entry also made npm v12 the latest release, with new install defaults. Dependency lifecycle scripts no longer run unless allowed, and git and remote URL dependencies are not resolved unless allowed. That is older news, but it explains failed builds on teams that upgraded npm without reading the notes. GitHub’s fix is to run npm approve-scripts --allow-scripts-pending and commit the resulting allowlist in package.json.
Who this affects in an ecommerce team
Most merchants never publish to npm. Plenty of in-house teams and agencies do, often without calling it publishing: a private scoped package of shared storefront components, a client library for an ERP or PIM API, or a design system shared by a headless storefront and a marketing site. These packages tend to publish from CI with a long-lived token created years ago, set to bypass 2FA so the pipeline would not stall. That pattern loses direct publishing in January.
Teams that only consume packages also benefit. GitHub’s stated reason for the July restriction is that a leaked bypass token could be used to take over an account. The less a stolen token can do on its own, the less likely it is that a package in your storefront build gets a malicious version pushed without a human seeing it.
We would run the first staged publish on a throwaway prerelease version of a private package. If the approval step is misconfigured, it then blocks a test build instead of a real release the week before a sale.





