You can support us by downloading this article as PDF from the Link below. Download the guide as PDF

In this tutorial, you will learn to install Node.js 14 on CentOS 8/7 & RHEL 8/7 Linux server or Desktop Workstation. Node.js is a server-side scripting language based on the V8 JavaScript engine, a Google Project. The Node.js I/O model, which is based on events and non-blocking operations enables a Developer to write efficient applications. The features of Node.js can be extended with tons of npm modules available.

Ubuntu / Debian installation: Install Node.js 14 on Ubuntu & Debian

Installing Node.js 14 on CentOS 8/7 & RHEL 8/7

An setup script is available which eases the installation of Node.js 14 on CentOS 8/7 & RHEL 8/7. You don’t need to build binaries from source code. The process is as simple as pulling the script and executing it, then run yum install commands.

The script will import RPM GPG key for the repository and create a repository file for Node.js packages.

Run Node.js installer script

Download and execute the script.

sudo yum -y install curl
curl -sL https://rpm.nodesource.com/setup_14.x | sudo bash -

Install Node.js 14 on CentOS 8/7 & RHEL 8/7

The installation on RHEL 8 is same as for RHEL 7 based Linux distributions. The only difference is that Node.js AppStream repository has been disabled on RHEL / CentOS 8 system by the setup script. If you ever want to install the AppStream version of Node.js, you’ll need to enable it.

sudo yum install -y nodejs

The command will install both Node.js 14.x and npm. Version installed can be checked with below command:

$ node -v
v14.0.0

To install the Yarn package manager, run:

curl -sL https://dl.yarnpkg.com/rpm/yarn.repo | sudo tee /etc/yum.repos.d/yarn.repo
sudo yum install yarn

If you need to build native add-ons for Node.js, consider installing the Development Tools.

sudo yum install gcc-c++ make

Some books you can check on Node.js:

Best Books for Learning Node.js / AngularJS / ReactJS / ExpressJS

You can support us by downloading this article as PDF from the Link below. Download the guide as PDF