Programming

4 Steps to Install Nodejs on Ubuntu 20.04

In this article, we’ll explain 4 steps to install Nodejs on Ubuntu 20.04.

Node.js is an open-source, cross-platform, back-end JavaScript runtime environment that executes JavaScript code outside a web browser.

Prerequisites

Step 1 – Keep the server up to date

# apt update -y

Step 2 – Download NodeJS

Download latest stable release of NodeJS.

# curl -sL https://deb.nodesource.com/setup_15.x | sudo -E bash –

Step 3 – Install NodeJS

Next, install the NodeJS using following command:

# apt-get install -y nodejs

Step 4 – Verify the installation

# node -v && npm -v

Output:

v15.6.0
7.4.0

That’s it. The installation has been completed successfully.

In this article, we have seen 4 steps to install Nodejs on Ubuntu 20.04.

Related Articles