How to update to the latest npm version

Posted in Tutorials

Tweet This Share on Facebook Bookmark on Delicious Digg this Submit to Reddit

To update your npm to the latest version, do …

npm install -g npm@latest

This is an instance where you use npm to update itself.  The -g flag is to install it “globally” which is commonly the case for command line programs.

For reference see doc from the npm site.