To install NPM, you have to intall Node.js first into your computer.

To install Node.js, go to this website and download by following instructions stipulated in the Node.js official website.

To check if you have Node.js installed, run this command in your terminal:

node -v

To confirm that you have npm installed you can run this command in your terminal:

npm -v

After installation of Node.js is done, you are recommended to update the NPM by running this command in your terminal:

npm install npm@latest -g

You are recommended to update the NPM from time to time.

Last modified: May 22, 2017

Author