How to upgrade npm in Windows?

Option 1. Upgrade Node.js and npm

You can upgrade Node.js, and the installer will upgrade npm too.

Option 2. Upgrade npm only from the command line

Use PowerShell (you should run it with an Administrator permissions):

Set-ExecutionPolicy Unrestricted -Scope CurrentUser -Force
npm install -g npm-windows-upgrade
npm-windows-upgrade

stackoverflow.com/a/31520672

See also: How did I upgrade Node.js in Windows?