Skip to content

Instantly share code, notes, and snippets.

@pleunv
Last active August 29, 2015 14:26
Show Gist options
  • Save pleunv/b5b197475ac496dc9ca7 to your computer and use it in GitHub Desktop.
Save pleunv/b5b197475ac496dc9ca7 to your computer and use it in GitHub Desktop.
Upgrading NodeJS & NPM on Windows

Upgrade NodeJS on Windows

  • 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.

Upgrade NPM on Windows

  • 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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment