- Uninstall the current version via Programs and Features.
- Download the latest version from the NodeJS website. (32-bit version is prefered, 64-bit should also work but I haven't tried this one recently)
- Install. This contains a bundled version of NPM which will have to be manually updated afterwards.
- Install the npm-windows-upgrade package globally:
npm install -g npm-windows-upgrade
. - The first time you do this you might have to enable scripting on your system:
- Open up a Powershell commandline in Administrator mode
- Type the following command:
Set-ExecutionPolicy Unrestricted -Scope CurrentUser -Force
- Open op a Powershell commandline in Administrator mode
- Run 'npm-windows-upgrade'
- Select the latest v2.* version (at this time this is v2.13.3, as v2.13.4 is not yet stable). NPM v3 is still in alpha-phase so should be avoided for now.
- Make sure
npm -v
outputs the version you have just installed.
the npm-windows-upgrade tool can also be used to downgrade to an older version.