How to Install Node.js on Ubuntu 24.10

To install Node.js on Ubuntu 24.10, follow these simple steps:

Step 1 : Run the following command to ensure your package lists are up-to-date:

Step 2 : Install necessary tools like ca-certificates, curl, and gnupg:

Step 3 : Import the NodeSource GPG key:

Step 4 : Add the Node.js repository for the desired version (e.g., 22.x):

Step 5 : Update the package list again to include the Node.js repository:

Step 6 : Install Node.js along with npm:

Step 7 : Check the installed versions of Node.js and npm to confirm:

Congratulations! You have successfully installed Node.js and npm on Ubuntu 24.10.