AI Workshop: learn to build apps with AI →
Setup and Installation: How to install Node.js

Join the AI Workshop and learn to build real-world apps with AI. A hands-on, practical program to level up your skills.


Node.js can be installed in different ways.

Let me show you the most common and convenient ones.

Official packages for all the major platforms are available at https://nodejs.org/en/download/.

There you can choose to download an LTS version (LTS stands for Long Term Support) or the latest available release. As usual, the latest version contains the latest goodies.

On the site they have packages for Windows, Linux, macOS.

One very convenient way to install Node.js is through a package manager. In this case, every operating system has its own.

On macOS, Homebrew is the de-facto standard, and, once installed, allows you to install Node.js very easily, by running this command in the terminal:

brew install node

Other package managers for Linux and Windows are listed in https://nodejs.org/en/download/package-manager/

nvm is a popular way to run Node. It allows you to easily switch the Node version, and install new versions to try and easily rollback if something breaks, for example.

It is also very useful to test your code with old Node versions.

See https://github.com/creationix/nvm for more information about this option.

My suggestion is to use the official installer if you’re just starting out and don’t use Homebrew already. Otherwise, Homebrew is my favorite because I can easily update Node by running brew upgrade node.

In any case, when Node is installed you’ll have access to the node executable program in the command line.

Lessons in this unit:

0: Introduction
1: How to fix the Homebrew error `Permission denied @ apply2files`
2: How to update Node.js
3: ▶︎ How to install Node.js
4: The Node.js Runtime v8 options list
5: Ubuntu how to upgrade Node.js