In this tutorial, you will learn how to install the latest version of Node JS on Ubuntu and Windows OS.
Install Node JS on Ubuntu
Before installing the Node.js, you have to specify the version number of the Node.js (which version you want to install).
/setup_version
.x – The following command will set the node version 14, but if you want to install version 15, you can replace setup_14.x with setup_15.x. Check out the latest version of the node.js.
curl -sL https://deb.nodesource.com/setup_14.x | sudo -E bash -
Now run the following command to install the specified version of Node.js.
sudo apt-get install -y nodejs
After successfully installing the node.js, you can confirm by checking the node and npm version.
Use the following command to check the node and npm version –
# Node Version
node -v
# npm version
npm -v
For more details, you can read the official documentation.
Node.js on Windows 10
If you are a Windows user, then go to the official site and download the latest stable version of the Node.

After successfully downloading the installer, now double click on it to start the installation setup.
#1 Click on the Next –

#2 Accept the terms and click Next –

#3 Choose where you want to install the node, or you can leave it as the default, then click Next –

#4 Click on the Next > Next > Install > Finish





After successfully installing the node.js, now to confirm that – open your PowerShell and check the node and npm version by using the following command –
# Node Version
node -v
# npm version
npm -v
