How to Install Node Js & NPM Ubuntu 20.04

NPM is a node package manager. NPM is the package manager for the Node JavaScript platform. It puts modules in place so that node can find them, and manages dependency conflicts intelligently. It is extremely configurable to support a wide variety of use cases. Most commonly, it is used to publish, discover, install, and develop node programs.

Install Node Js & NPM in Ubuntu 18.04, 20.04 and 22.04; In this tutorial, i am going to show you how to install Node Js & NPM on Ubuntu.

How to Install Node Js & NPM Ubuntu 20.04

Step 1 – Update System Packages

Step 2 – Add Node.js PPA

Step 3 – Install Node.js and NPM On Ubuntu

Step 4 – Test Version

Step 1 – Update System Packages

First of all, open terminal and execute the following command into it to update the apt package:

sudo apt-get update

sudo apt-get upgrade

Step 2 – Add Node.js PPA

PPA (Personal Package Archives) is Python software libraries. Before install node js & npm on ubuntu, first install PPA in our ubuntu system. Using this below commands.

sudo apt-get install python-software-properties

curl -sL https://deb.nodesource.com/setup_11.x | sudo -E bash -

Step 3 – Install Node.js and NPM On Ubuntu

Once the ppa package is added, then execute the following command on terminal to install node js & npm on Ubuntu:

sudo apt-get install nodejs

For Install NPM on Ubuntu

sudo apt-get install npm

Step 4 – Test Version

Once the installation is done, execute the folllowing command on terminal to check the version:

nodejs  -v

Check the Installed NPM version :

npm -v

Conclusion

In this tutorial, i have shown you how to install Node js & NPM on Ubuntu 18.04/20.04/22.04.

One Comment

  1. Jhanvi Mehta said:

    Well-written Article! Your article provides step-by-step information so that was easy to understand for beginners. so, thank you for this article and you have any tips and tricks about node.js then keep sharing.

    January 13, 2022
    Reply

Leave a Reply

Your email address will not be published.