Skip to content

Developer & Productivity Tools · Freemium

npm

npm is the default package manager for JavaScript and Node.js, and the name of the public registry it installs from. The npm command-line client ships with Node.js, and the registry at npmjs.com hosts public and private packages for individuals and organizations. npm, Inc. has been part of GitHub since 2020, and npm product changes are announced on the GitHub changelog.

Who it is for: anyone who installs JavaScript dependencies, and anyone who publishes packages, from a single-library maintainer to a team shipping dozens of packages from one monorepo. For most developers npm is invisible plumbing. For maintainers, the parts that matter are publishing access, tokens and release automation, which is where most supply-chain attacks on the registry have started.

Key features, according to the npm documentation: - The npm CLI (version 12 is the current major line) for installing, auditing and publishing packages, with workspaces for monorepos. - Scopes, organizations and teams for managing who can publish which packages, and per-package publishing access settings that can require two-factor authentication (2FA) and disallow tokens. - Granular access tokens with per-package permissions, including a stage-only option that can submit a release for review but cannot publish it directly. - Trusted publishing with OpenID Connect (OIDC) from GitHub Actions, GitLab.com shared runners and CircleCI cloud, which replaces long-lived publish tokens with short-lived ones. Self-hosted runners are not supported yet. - Staged publishing: npm stage publish puts a version in a private staging area, and a maintainer approves it with 2FA before it becomes installable. Since 30 November 2026, maintainers can approve up to 100 staged versions, one per package, in a single batch on npmjs.com with one 2FA challenge. - Provenance statements, ECDSA registry signatures and npm audit for checking where a package came from and whether it has known vulnerabilities.

Pricing type: freemium. Publishing and installing public packages is free; private packages need a paid user or organization plan. Check the npm website for current plan prices.

Changes to plan for: npm is targeting January 2027 to stop granular access tokens that bypass 2FA from publishing directly. After that, those tokens can only read private packages and stage a release, so automated publishing has to move to trusted publishing or to staged publishing with a human approval.

Alternatives: pnpm, Yarn and Bun are alternative clients that still install from the npm registry; GitHub Packages and JSR are alternative registries for some use cases.

Official site: https://www.npmjs.com/

Official site