Installing ReactJS and creating your first application on Windows Setup

03 October 2018

Here we will see how to install React.js on Windows setup.

1. Install Node.js and NPM on Windows

In order to install Node.js for Windows, you need to head over to the Node.js website and download the Windows version which is recommended for most users. Afterward, you should install it. NPM comes automatically with Node.js. You’ll need to have Node >= 6 and npm >= 5.2 on your machine.
Now, you should check whether the Node.js installation for Windows was successful with below commands from command prompt.
For Node Version

node --version

For NPM version

npm --version

2. NPM on the Command Line for create-react-app

2.1 Open CMD from your windows and go to your desired location and than run this command

npm install -g create-react-app

And once it’s successfully done, after that use this command.

npx create-react-app react-app

here you can keep any name instead of ‘react-app’

2.2 Now go into the newly created folder with the command prompt

cd react-app

2.3 Now Start the development server

npm start

Now you will see your React application on your browser at “http://localhost:3000/”.

Leave a Comments