Skip to content

rishit-exe/WeatherApp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

2 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🌀️ Modern Weather App – Java GUI + Weather API

Weather App
API

πŸš€ Overview

Modern Weather App is a sleek, GUI-based weather application built with Java Swing and styled using FlatLaf for a modern look. It fetches real-time weather data from WeatherAPI and displays temperature, humidity, and conditions with beautiful icons.


🎨 Features

βœ… Modern UI – Styled with FlatLaf for a professional look
βœ… Live Weather Data – Fetches real-time weather using WeatherAPI
βœ… Weather Icons – Displays accurate icons based on conditions
βœ… Responsive Design – Auto-adjusts for different screen sizes
βœ… Error Handling – Displays alerts for invalid city names


πŸ› οΈ Tech Stack

πŸ”Ή Java – Core logic & API calls
πŸ”Ή Swing (JFrame, JPanel, JButton, JLabel, etc.) – GUI Components
πŸ”Ή FlatLaf – Modern UI Look & Feel
πŸ”Ή WeatherAPI – Real-time weather data
πŸ”Ή JSON Parsing – Fetch and display weather conditions


πŸ“¦ Installation & Setup

1️⃣ Clone the Repository

git clone https://github.com/your-username/ModernWeatherApp.git
cd ModernWeatherApp

2️⃣ Get a Free API Key from WeatherAPI

  1. Go to https://www.weatherapi.com/
  2. Sign up and generate a free API key
  3. Copy the key and replace YOUR_WEATHERAPI_KEY in ModernWeatherApp.java:
    private final String API_KEY = "YOUR_WEATHERAPI_KEY";

3️⃣ Install FlatLaf (for UI styling)

  • Download FlatLaf JAR from: https://mvnrepository.com/artifact/com.formdev/flatlaf
  • Add the JAR to your project:
    • IntelliJ: File > Project Structure > Libraries > Add JAR
    • VS Code (Command Line):
      javac -cp ".;lib/flatlaf-3.2.jar" ModernWeatherApp.java
      java -cp ".;lib/flatlaf-3.2.jar" ModernWeatherApp

πŸš€ Running the Application

javac ModernWeatherApp.java
java ModernWeatherApp

⭐ Star the Repo

If you like this project, don’t forget to ⭐ star the repo!

Your support helps me improve and add more cool features! πŸš€πŸ”₯

About

Under Development WeatherApp with a user-friendly UI

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages