How to Install Latest Node.js 22 on Ubuntu 26.04 with PPA

Node.js is a platform built on Chrome’s JavaScript runtime to build fast and scalable network applications.
The latest version of the Node.js PPA is maintained officially.

Add Nodesource PPA

First, add the PPA to your Ubuntu system by running the following commands:

apt install curl ca-certificates gnupg -y
curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash -

Output:

root@vps:~# curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash -
...
Repository configured successfully.
To install Node.js, run: apt install nodejs -y

Install Node.js

Now, install the latest version of Node.js by running:

apt install nodejs -y

Output:

root@vps:~#  apt install nodejs -y
Installing:
  nodejs

Summary:
  Upgrading: 0, Installing: 1, Removing: 0, Not Upgrading: 2
  Download size: 37.9 MB
  Space needed: 236 MB / 7,416 MB available

Get:1 https://deb.nodesource.com/node_22.x nodistro/main amd64 nodejs amd64 22.22.2-1nodesource1 [37.9 MB]
Fetched 37.9 MB in 1s (25.7 MB/s)
Selecting previously unselected package nodejs.
(Reading database… 118321 files and directories currently installed.)
Preparing to unpack …/nodejs_22.22.2-1nodesource1_amd64.deb…
Unpacking nodejs (22.22.2-1nodesource1)…
Setting up nodejs (22.22.2-1nodesource1)…
Processing triggers for man-db (2.13.1-1build1)…
Scanning processes...

Verify Node.js Version

After installation, verify the Node.js version:

node -v

Output:

root@vps:~# node -v
v22.22.2

🎉 Done! Node.js 22 is successfully installed on Ubuntu 26.04.


CrownCloud - Get a SSD powered KVM VPS at $4.5/month!
Use the code WELCOME for 10% off!

1 GB RAM / 25 GB SSD / 1 CPU Core / 1 TB Bandwidth per month

Available Locations: LAX | MIA | ATL | FRA | AMS