How to install Node, Yarn, Git and VSCode on Linux, Mac and Windows

On Linux (Ubuntu 20.04 LTS):

Download the Node LTS archive file from and extract it (in this example, the archive is extracted is /home/user/Downloads/)

Open .bashrc in the home folder (/home/user./bashrc) with a text editor, and append:


Then, in a terminal:

source .bashrcnode -v
# v14.17.0
npm -v
# 6.14.13

You may also need the development tools to build native addons:

sudo apt install gcc g++ make

Alternatively, you can install Node from a package. To install the LTS version, go to and

# You need to install curl if it's not already installed
sudo apt install curl

# Ubuntu
curl -fsSL | sudo -E bash -
sudo apt-get install -y nodejs

Install Yarn (from

npm install -g yarn

yarn -v
# 1.22.10
sudo apt install git

Download the .deb package from Then, in a terminal, go to the Downloads folder, and:

sudo dpkg -i code_1.57.0-1623259737_amd64.deb

# test it
code .

On Mac

Download the LTS package from and install it (double click on node-v14.17.1.pkg and follow the steps).

Then open a terminal, and:

node -vnpm -v

Open a terminal, and:

npm install -g yarnyarn -v

NOTE: if you get this error: “npm WARN checkPermissions Missing write access to /usr/local/lib/node_modules/yarn” run the following commands:

sudo chown -R $USER /usr/local/lib/node_modules 
sudo chown -R $USER /usr/local/bin
sudo chown -R $USER /usr/local/share/

Then try to reinstall yarn with the command above.

First, install Homebrew by following the instructions here:

Then, install Git with:

brew install git

Download the package from and install it.

On Windows

Download Nodejs LTS from and install the package — don’t forget to check “Automatically Install the Necessary Tools” in the installer.

Then, open a terminlal (Command Prompt) and:

node -vnpm -v
npm install -g yarnyarn -v

Download the executable from here and run the installer.

Then, open a terminal and:

C:\Users\user>git --version
git version

Download VSCode from and run the installer.

Then, to test everything, open a Command Prompt and:

git clone projects\react-appyarn init --yesyarn add react react-domyarn add --dev @types/react @types/react-dom ts-loader css-loader html-webpack-plugin node-sass sass-loader style-loader typescript webpack webpack-cli webpack-dev-server# Open VSCode
code .

Open package.json and append these lines:

,"scripts": {
"clean": "rm -rf dist/*",
"build": "webpack",
"dev": "webpack serve"

Run yarn dev, open a browser and go to http://localhost:8080/




Love podcasts or audiobooks? Learn on the go with our new app.

Intro to Redux (React-Redux).

Notes on Prototype Inheritance and Composition in JS

How The React JS is Changing Front-End Development

Creating a Bug Report Form in GitHub

A Faint Outline

Creating Dynamic Discord Bots with JavaScript ES6 and Realm

React Hooks — A Conceptual Overview

Node.js REST API with RBAC, JWT, Repository and MVC pattern. Part 3.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
alex adam

alex adam

More from Medium

Backup your database using cron

Getting started with Git: made easy

How to install JDK on mac M1/aarch64/ARM natively

VS Code Remote Container User