'npm is not recognised as an internal or external command - install using nvm

I am trying to install nodejs and npm on my Windows 10 PC. Below are the steps I followed for the same

  1. Downloaded nvm set up from here
  2. Installed nvm install wizard using nvmsetup.exe
  3. Opened command prompt and typed in 'nvm install v5.1.0
  4. typed in nvm use 5.1.0
  5. typed in node -v and got the response back v5.1.0
  6. but when I tried npm --version I am getting error saying npm is not recognized as an internal or external command

I updated the environment variables to set the PATH C:Program Files\nodejs. Restarted PC, and restarted Command prompt still no luck. Really appreciate any help on this. thanks



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source