SkyCast is a full-stack weather dashboard that displays real-time weather and 5-day forecasts for any city, powered by OpenWeatherMap and Spring Boot backend.
- Search weather and forecast for any city
- Responsive, modern UI (React)
- Backend API (Spring Boot) fetches and combines current and forecast data
- CORS enabled for local development
frontend/— React app (UI)WeatherApp/— Spring Boot backend (API)
- Go to
WeatherApp/ - Build and run:
- Windows:
mvn spring-boot:run - Backend runs on
http://localhost:8080
- Windows:
- API endpoint:
GET /api/weather?city=CityName
- Go to
frontend/ - Install dependencies:
npm install - Start app:
npm start- Frontend runs on
http://localhost:3000
- Frontend runs on
- Enter a city name and click "Search"
- View current weather and 5-day forecast
OpenWeatherMap API key is set in both frontend and backend. You can change it in:
frontend/src/App.jsWeatherApp/src/main/java/com/harshweather/service/WeatherService.java
- If you see CORS errors, make sure backend is running and endpoint is
/api/weather. - If forecast cards repeat, only one card per day is shown (filtered by 12:00 PM in frontend).
MIT