Tech

npm (Node Package Manager)

Definition

The default package manager for Node.js that allows developers to install, share, and manage JavaScript libraries and their dependencies.

Try the free calculator

Use our JSON Formatter to run the numbers yourself.

npm is the world's largest software registry and the default package manager for the Node.js JavaScript runtime. It provides a command-line interface (CLI) for installing packages and a web-based registry (npmjs.com) hosting over 2 million open-source packages.

The package.json file in a project's root defines its dependencies and metadata. Running npm install reads this file and downloads all required packages into the node_modules directory. Lock files (package-lock.json) ensure reproducible builds by recording exact dependency versions.

Key npm commands include npm install (add dependencies), npm run (execute scripts), npm publish (share packages), and npm audit (check for security vulnerabilities). Alternative package managers like Yarn and pnpm offer different approaches to dependency management with various performance and feature trade-offs.

Related Calculators

Related Terms

Related Articles

Stay Updated

Get notified about new tools, features, and exclusive deals. No spam, ever.