Hello NodeJS Friends,
Through this NodeJS tutorial, you will learn How to Install NodeJS on MacOS.
Whether you’re a web developer or a system administrator, knowing how to install Node.js is a fundamental skill. Node.js development environment can be set up in Windows, Mac, Linux and Solaris.
Let’s walk through the installation process of node.js on the Mac operating system.
Prerequisites to Install Node.js
The following tools/SDK are required for developing a Node.js application on any platform.
- Node Package Manager (NPM)
- IDE (Integrated Development Environment) or TextEditor
Install Node js on Mac
To install Node.js on a Mac, you have a few options. Below, I’ll outline two common methods: downloading the official installer from the Node.js website and using Homebrew (a package manager).
Method 1: Using the Official Installer
You can download and install Node.js manually from the official website:
Step 1: Visit Node.js site https://nodejs.org/en/download
Step 2: Click on the appropriate installer for Mac (.pkg or .tar.gz) to download the Node.js installer.
Step 3: Once downloaded, click on the installer to start the node.js installation wizard and finish the steps.
Step 4: After the successful installation, open terminal/cmd and check the version of the node using the below command.
$ node -v
Method 2: Using Homebrew (Recommended)
Homebrew is a popular package manager for macOS that simplifies the installation and management of software. You can install directly using the homebrew package manager using the following command.
$ brew install node
Share the tutorial with your friends and stay updated to learn more about NodeJS.