How to Install Node.js on Windows and Mac

December 24, 2023

What Is Node.js?

Node.js is a pivotal technology conceived by Ryan Dahl in 2009 to redefine server-side scripting. Going beyond conventional boundaries, it is a dynamic force in digital architecture. This JavaScript runtime unifies frontend and backend development, liberating developers from traditional constraints. Its brilliance lies in executing JavaScript beyond browsers, offering a versatile platform for scalable applications.

Node.js encapsulates a comprehensive philosophy, embodying principles of agility and responsiveness. It becomes a dynamic core for real-time applications, influencing major e-commerce entities and collaborative tools. Node.js remains a testament to the adaptability and enduring influence in a digital age defined by innovation. Now, let’s look into how to install Node.js so you can start taking advantage of this powerful program as soon as possible!

How to Install Node.js?

So, you've caught the Node.js bug and want to dive in? Awesome choice! Let's make the process of getting it on your machine a breeze. In this quick guide, we'll walk through the easy steps to download and install Node.js on both Windows and Mac. Whether you're a coding ninja or just starting your journey, we've got you covered. Ready to roll? Let's do this!

How to Install Node.js on Windows

Step 1: Download the Node.js Installer

To download the installer, you need to go to the nodejs.org website. You can use this link:  https://nodejs.org/en/download. When you are there, click the “Windows Installer” button to download the recommended installer.

Install node.js Windows

Step 2: Install Node.js

  1. To install Node.js, we must use the installer we just downloaded. To do that, open the downloads tab in your browser and open it from there, or go to the location in your files where you downloaded the installer and double-click on it to launch the setup wizard.
  2. You may get a notification from Windows to let the installer run. Click allow, and you will see the set-up wizard pop up.
  3. First, the installer will notify you that it will install Node.js on your computer, but we already know that, so click “Next.”
  4. Next, you can read the License Agreement. If you agree, check the “I accept the terms in the License Agreement” checkbox and click “Next.”
  5. Now, you can choose where to install the program.  A default installation path will already be selected for you, but if you wish to install the software somewhere else, you are free to choose another location for the installation. After you have decided where to install the program, click on “Next.”
  6. The wizard will allow you to select which parts of the program to download. Unless you need anything specific, you can click on “Next.”
  7. Now, you can press “Install” to start the installation of Node.js. Wait for the installation to complete. This process shouldn’t take more than a few minutes. When it’s done, click “Finish.”

Congrats! Now you have Node.js installed on your system! But we are not done yet. Verifying if the program has been installed correctly is a good idea. To learn how to do that, proceed to step 3.

Step 3: Verify installation

To make sure you have set up Node js correctly, open Command Prompt by writing “cmd” in the Windows search bar or by pressing “Windows Button” and “R” at the same time, then write “cmd” and press “Enter.”

Now that you are in Command Prompt, to check if you have installed the program correctly, write “node -v.” If Node.js has been installed correctly, you will be shown the version of the installation like in this screenshot:

Node.js installation on Windows

How to install Node.js on MAC

Step 1: Download the Node.js installer 

To download the installer, you need to go to the nodejs.org website. You can use this link:  https://nodejs.org/en/download. When you are there, click the “macOS Installer” button to download the recommended installer.

Install node.js Mac

Step 2: Install Node.js

  1. Now, how to install Node.js? To start the installation, you first need to run Node.js installer.
  2. After opening the installer, you will be met with an introduction page showing you what will be installed. Press “Continue.”
  3. Then, you will be able to read the Software License Agreement. If you agree with the agreement, press “Continue” and then “Agree”.
  4. After that, you will have the option to choose a location for the installation. A default installation path will already be selected for you, but if you wish to install the software somewhere else, you are free to choose another location for the installation. After you have decided where to install the program, press “Install.”
  5. Wait for the installation to complete. This process shouldn’t take more than a few minutes. After the installer has done its job, press “Close.”

Congrats! Now you have Node.js installed on your system! But we are not done yet. Verifying if the program has been installed correctly is a good idea. To learn how to do that, proceed to step 3.

Step 3: Verify installation

After you have completed the installation, you need to check if Nodejs is installed properly, open your terminal and write “node -v”. If the program is installed correctly, the terminal will show your current version of Node.js.

Conclusion 

Congratulations on successfully completing the journey on how to install Node.js! You've now unlocked a gateway to the forefront of cutting-edge web development. With this powerful JavaScript runtime conveniently at your fingertips, your coding ventures are poised to ascend to new heights. Regardless of whether you're a seasoned coding master or a still learning novice, Node.js stands ready to empower you to go and create dynamic and highly efficient applications. Now that you have installed Node.js, you have opened the door to a world of immense coding possibilities. Happy coding! The digital landscape awaits your innovative touch.

Subscribe to Codelevate

Get our newest tips directly in your inbox!

Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.