How to install NodeJS 4.x on Ubuntu

Via NVM (Node Version Manager)

# get the latest nvm release
curl | bash

# OR
wget -qO- | bash

# Restart your terminal or run
source ~/.profile

# Install the NodeJS version needed
nvm install 4.1

# update npm
npm install npm -g


curl -sL | sudo bash -
sudo apt-get install -y nodejs

# update npm
npm install npm -g

Leave a Reply

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