How to Install Node.js and NPM on Windows

I am going to show you how to install node.js (zip) on Windows OS (Operating System). Node.js is a JavaScript runtime built on Chrome’s V8 JavaScript engine and it uses an event-driven, non-blocking I/O model that makes it lightweight and efficient. Node.js package ecosystem, npm, is the largest ecosystem of the open source libraries.

Here I am going to show you how to install zip version of node.js, not Windows installer (msi). Installing zip archive of the software has some benefits, such as, you don’t need to remove anything from registry if anything goes wrong while removing the software, you do not worry about installation process if anything goes wrong.

Prerequisites

Node.js 12.18.3/14.15.5, Windows 10 64 Bit OS

Installation Steps

1. Download node.js binary(.zip) depending on your Windows is 32 or 64 bit OS from URL https://nodejs.org/en/download/.

node.js download

2. Extract the downloaded zip folder into C:\ drive or any other drive or folder as per your convenience.
3. Add nodejs and npm/bin folder to environment variable path respectively as shown in the below figures.

node js installation environment path

Finally edit Path or PATH variable and add above two variables to the path. Something similar to below

;%NodeJS%;%NoseJSnpm%;

If you are on Windows OS 10 then add above variable one by one as a separate row.

node.js setup

4. Open command prompt and check the version of the node and npm. So it means your node.js installation was successful.

node.js version

5. Optionally if you want you can update node.js to latest version. On a command prompt execute npm install -g npm to update npm to the latest version.

If you are facing any error (Refusing to delete npm.cmd: is outside ...) during update to npm latest version then you can use command npm install -g --force gatsby-cli.

That’s all about installing nodejs and npm in Windows environment.

Author: Soumitra

Hi, I am, Soumitra, the owner of roytuts.com and it is my passion for sharing my knowledge and I have been writing blogs on various technologies since 2014. If you like my tutorials, you may also want to like my Facebook Page, follow me on Twitter, Github.

1 thought on “How to Install Node.js and NPM on Windows

Leave a Reply

Your email address will not be published. Required fields are marked *