Deploy Your App to Netlify
Deploy Your App to Netlify
Let’s now take your GitHub-hosted project live using Netlify, a popular and beginner-friendly hosting service for front-end apps.
Step 1: Build Your React App
In your terminal, run:
npm run build
This creates a new build/ folder with production-ready files. Make sure you run this command from the root of your weather app project (where package.json is located).
Step 2: Sign Up or Log in to Netlify
- Go to Netlify.com and create a free account or log in.
- Click "Add new site" → "Import an existing project".
- Choose GitHub and authorize Netlify to access your repositories.
- Select your react-weather-app repo.
Step 3: Configure Build Settings
Set these values:
Setting | Value |
| Build Command | npm run build |
| Publish Directory | build |
Leave all other settings as default, then click Deploy Site.
Netlify will take a minute or two to build and deploy your app.
Step 4: Your Site Is Live
Once deployment is complete, Netlify will give you a random live URL like:
https://your-weather-site.netlify.app/
You can rename this URL:
- Go to your Site Settings on Netlify.
- Click Change site name and enter something like:
guvi-weather-app-jaishree


