DEV Community

Cover image for Deploy your react app on netlify for free
Sourav das
Sourav das

Posted on

3 3

Deploy your react app on netlify for free

In this post i will show you how to deploy your react app on netlify
It is simple :)

1 install netlify cli using npm

npm install netlify-cli -g
Enter fullscreen mode Exit fullscreen mode

2 run:- npm run build

Open your project folder in terminal and run this command

npm run build
Enter fullscreen mode Exit fullscreen mode

it will generate a build directory

3 run:- netlify deploy

Continue the further process like name your website whatever you want but care fully choose the ./build directory for deploy
the_terminal_image

then you will get a website_draft_url check the link and if you see your website all content and functionality is ok then proceed to further step .

now if you want to view your actual webaddress you will find the page not found message so then you have to do,

4 deploy it on your actual domain which you chose

now your website is live but web address looks horrible so
run

netlify deploy --prod
Enter fullscreen mode Exit fullscreen mode

Then you will finally see your app on web address like
yourwebsitename.netlify.app

Sentry image

Hands-on debugging session: instrument, monitor, and fix

Join Lazar for a hands-on session where you’ll build it, break it, debug it, and fix it. You’ll set up Sentry, track errors, use Session Replay and Tracing, and leverage some good ol’ AI to find and fix issues fast.

RSVP here →

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs