npm Set Visual Studio Compiler Version

Node.js or io.js will sometimes require a C++ compiler to build packages for you. On Microsoft Windows you can use Visual Studio. The newer free Visual Studio Community or the older (and also free) Visual Studio Express editions should get you going if you don't have a commercial copy of Visual Studio.

To check the compiler npm is configured to use try:

npm config list

and check the msvs_version value.

You can specify a Visual Studio version for npm to use.

npm config set msvs_version 2013


npm config set msvs_version 2013 --global

Another option is to run


You can use other Visual Studio version numbers like 2012, 2010 etc.

There is also a Visual Studio plugin called Node.js Tools for Visual Studio that is quite useful. It is free and open source.