Install Node.js

Summary: in this tutorial, you will learn how to install Node.js on your computer.

Download Node.js

To download Node.js, you go to the download page on the Node.js website.

Node.js supports multiple platforms, including Windows, macOS, and Linux. You need to select the installer that’s suitable for your platform to download.

Node.js has two actively supported releases: Long-Term Support (LTS) and Current. If you develop applications for real uses, you should only use the LTS releases.

The LTS release is recommended for most users. Typically, LTS releases guarantee that critical bugs will be fixed for a total of 30 months. The Major Node.js enters the Current release status for six months.

Install Node.js on Windows

To install Node.js on Windows, double-click the installer file that you have dơnload to launch the setup wizard.

First, the setup wizard will compute space requirements:

Once completed, you click the Next button to go to the next step:

Second, you need to accept the end-user license agreement and click the Next button.

Third, you can select a folder to install Node.js and click the Next button. It defaults to C:\Program Files\nodejs\.

Fourth, select the features that you want to install and click the Next button. If you leave the default options, the setup wizard will install Node.js runtime, npm package manager, and online documentation shortcuts. It also adds the C:\Program Files\nodejs\ folder to the PATH:

Fifth, select the checkbox to install the necessary tools, including Chocolatey. If you don’t know what it is, leave it unchecked and click the Next button.

Sixth, click the Install button to begin the installation.

Seventh, you need to wait for the setup wizard installs Node.js

Eight, click the Finish button to exit the setup wizard.

To confirm the installation, you can open Command Prompt or Windows Terminal and type the following command:

node -v

It will show the installed version of Node.js. If you type node, it will launch a REPL and put you in an interactive JavaScript environment. In this interactive mode, you can execute any valid JavaScript code.

> 'hello'.length
5
> 'hello'.toUpperCase();
'HELLO'
>Code language: JavaScript (javascript)

To escape the interactive mode, you type the .exit command:

>.exitCode language: CSS (css)

In this tutorial, you have learned how to download and install Node.js on your computer.

Was this tutorial helpful ?