npm (originally Node Package Manager) is a package manager for the JavaScript programming language. It functions as the default package manager for both JavaScript and TypeScript. npm is composed of an online registry containing public and private code packages, and a command-line interface (CLI) tool for interacting with the registry. It is the world's largest software registry, used by open-source developers to share software.
npm automates the process of managing reusable code modules, which is critical for both open-source collaboration and enterprise-scale development. The npm CLI tool allows developers to automate the discovering, installing, managing, updating, and publishing of project dependencies. The "npm install" command resolves dependencies and downloads packages, while "npm publish" uploads new or updated packages to the registry. npm is free to use and is installed with Node.js. Recent features have focused on security, including granular access tokens for automation and a code explorer to view package content directly in the npm portal.