sudo apt update
sudo apt install nodejs
sudo apt install npm
//Author: Mohammad Arman Khan
//How To Install Node.js on Ubuntu
1: sudo apt-get update
2: sudo apt-get install nodejs
3: sudo apt-get install npm
4: nodejs -v
sudo apt-get install curl
curl -sL https://deb.nodesource.com/setup_15.x | sudo -E bash -
sudo apt-get install nodejs
# Check node version
node -v
# v15.14.0
# Also, check the npm version
npm -v
# 7.7.6
sudo apt-get install curl
curl -sL https://deb.nodesource.com/setup_17.x | sudo -E bash -
sudo apt-get install nodejs
# First check latest version from site 'https://nodejs.org/en/'
$ sudo apt-get install curl
$ curl -sL https://deb.nodesource.com/setup_16.x | sudo -E bash -
$ sudo apt-get install -y nodejs
sudo apt-get install curl
curl -sL https://deb.nodesource.com/setup_13.x | sudo -E bash -
sudo apt-get install nodejs
node -v #to check if its installed
# Using Ubuntu
curl -fsSL https://deb.nodesource.com/setup_16.x | sudo -E bash -
sudo apt-get install -y nodejs
# Using Debian, as root
curl -fsSL https://deb.nodesource.com/setup_16.x | bash -
apt-get install -y nodejs
# See for the latest version https://github.com/nodesource/distributions/blob/master/README.md#debinstall
# assuming you have curl installed
curl -fsSL https://deb.nodesource.com/setup_14.x | sudo -E bash -
sudo apt-get install -y nodejs
curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -
sudo apt install -y nodejs
curl -sL https://deb.nodesource.com/setup_9.x | sudo -E bash -
sudo apt-get install -y nodejs