Learn how to install npm on your computer.
The Short Version
- Go to https://nodejs.org/en/
- Download and install the version named “12.6.3 LTS“.
The Details
npm doesn’t come in a stand-alone package, so you will need to install NodeJS to get npm. Follow these steps:
- Go to https://nodejs.org/en/
- Download and install the version named “12.6.3 LTS”. LTS stands for Long Term Support, and that is what most developers will want to use. The latest version as of the writing of this article was 12.6.3, but it may be a different number for you.
- Open a command shell.
- Confirm that npm is installed by running this command:
npm -v
If npm is installed correctly, the output should be the version number, for example:
12.6.3