A simple JavaScript weather application that fetches real-time weather data using the OpenWeatherMap API.
- Search for any city and get current weather details:
- 🌡 Temperature in Celsius
- 🌬 Wind speed
- 💧 Humidity
- 🌥 Weather description and icon
- Basic error handling (alerts user if the city is not found)
- JavaScript (ES6+)
- HTML/CSS
- OpenWeatherMap API
git clone https://github.com/yourusername/weather-app.git
cd weather-appNo need for a server. It's a pure frontend app using JavaScript.
This project uses a public weather API from OpenWeatherMap.
You can use the provided API key in this demo or get your own for free:
const weather = {
apiKey: "e14f135ff04a40d618f3ce5fb6ddc3fb", // replace this with your own key if needed
...
};/weather-app
├── index.html
├── style.css
└── script.js # Contains the weather logic
MIT — free to use and modify
