Weather MCP Server
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Weather MCP Serverwhat's the forecast for Tokyo this weekend in Fahrenheit?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Weather MCP Server 🌤️
A Model Context Protocol (MCP) server that provides weather information tools. This server enables AI assistants like Claude to fetch real-time weather data, forecasts, and compare weather across different cities.
Features
Current Weather: Get real-time weather information for any city
Weather Forecast: Get weather predictions for up to 10 days (based on API plan)
Weather Comparison: Compare weather conditions between two cities
Supports both Celsius (metric) and Fahrenheit (imperial) units
Related MCP server: Weather MCP Server
Prerequisites
Python 3.8 or higher
WeatherAPI.com API key (free tier available)
Installation
Clone the repository
git clone https://github.com/Abhishek3689/Weather_MCP_Server.git cd weather-mcp-serverInstall dependencies
pip install -r requirements.txtSet up environment variables
Create a
.envfile in the project root:WEATHER_API_KEY=your_api_key_hereGet your free API key from WeatherAPI.com
Usage
🚀 Running The Server (Important!) 👉 If you double-click or run the file, you will NOT see results.
MCP servers do not show output directly.
They wait for Claude to connect to them.
But you can still start the server manually to ensure it’s working:
python weather_server_mcp.pyYou would see somthing like this it means server is running correclty
╭──────────────────────────────────────────────────────────────────────────────╮
│ │
│ ▄▀▀ ▄▀█ █▀▀ ▀█▀ █▀▄▀█ █▀▀ █▀█ │
│ █▀ █▀█ ▄▄█ █ █ ▀ █ █▄▄ █▀▀ │
│ │
│ FastMCP 2.13.1 │
│ │
│ │
│ 🖥 Server name: Weather Server │
│ │
│ 📦 Transport: STDIO │
│ │
│ 📚 Docs: https://gofastmcp.com │
│ 🚀 Hosting: https://fastmcp.cloud │
│ │
╰──────────────────────────────────────────────────────────────────────────────╯Integration with Claude Desktop
To use this server with Claude Desktop, add the following to your Claude Desktop configuration:
On macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
On Windows: %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"weather": {
"command": "python",
"args": [
"weather_server_mcp.py"
],
"env": {
"WEATHER_API_KEY": "your_api_key_here"
}
}
}
}Note : for 'command' write absolute location instead of only "python" by checking using in command prompt
where pythonyou will see somthing like this
C:\Users\YourName\AppData\Local\Programs\Python\Python312\python.exeAfter updating the config, restart Claude Desktop.
Available Tools
1. Get Current Weather
get_current_weather(city: str, units: str = "metric")city: City name (e.g., 'London', 'New York', 'Tokyo')
units: 'metric' for Celsius or 'imperial' for Fahrenheit
Example:
get_current_weather("London", "metric")2. Get Weather Forecast
get_forecast(city: str, days: int = 3, units: str = "metric")city: City name
days: Number of forecast days (1-10)
units: Temperature units
Example:
get_forecast("Paris", days=5, units="metric")3. Compare Weather
compare_weather(city1: str, city2: str, units: str = "metric")city1: First city name
city2: Second city name
units: Temperature units
Example:
compare_weather("Tokyo", "New York", "metric")Project Structure
weather-mcp-server/
├── weather_server_mcp.py # Main MCP server implementation
├── requirements.txt # Python dependencies
├── .env # Environment variables (not committed)
├── .gitignore # Git ignore file
└── README.md # This fileAPI Information
This project uses the WeatherAPI.com service:
Free tier: 1,000,000 calls/month
3-day forecast on free plan
Real-time weather data
Historical weather data
Example Output
Current Weather in London, United Kingdom
📍 Location: 51.52, -0.11
🌡️ Temperature: 15°C
🤔 Feels Like: 14°C
☁️ Condition: Partly cloudy
💧 Humidity: 72%
🔽 Pressure: 1013.0 hPa
💨 Wind Speed: 15.1 kph
☁️ Cloudiness: 25%
👁️ Visibility: 10.0 kmContributing
Contributions are welcome! Please feel free to submit a Pull Request.
Fork the repository
Create your feature branch (
git checkout -b feature/AmazingFeature)Commit your changes (
git commit -m 'Add some AmazingFeature')Push to the branch (
git push origin feature/AmazingFeature)Open a Pull Request
License
This project is licensed under the MIT License - see the LICENSE file for details.
Troubleshooting
"WEATHER_API_KEY environment variable not set"
Make sure you've created a
.envfile with your API keyOr set the environment variable in your system/Claude config
"HTTP Error: 401"
Check that your API key is valid
Ensure the API key is correctly set in your
.envfile
"Only X days available"
Free tier of WeatherAPI.com provides 3-day forecasts
Upgrade to a paid plan for extended forecasts
Support
If you encounter any issues or have questions:
Open an issue on GitHub
Check the WeatherAPI.com documentation
Review the MCP documentation
Author
Project Link: https://github.com/Abhishek3689/Weather_MCP_Server
Acknowledgments
FastMCP - Framework for building MCP servers
WeatherAPI.com - Weather data provider
Anthropic - Claude AI and MCP protocol
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Flicense-qualityDmaintenanceEnables AI assistants to fetch current weather conditions and forecasts for any city using the Open-Meteo API. Provides temperature, precipitation, and hourly forecast data through natural language queries.Last updated
- Flicense-qualityDmaintenanceProvides weather information through OpenWeather API, enabling users to get current weather conditions, 5-day forecasts, and perform temperature conversions for any city. Offers a secure interface for AI assistants to access comprehensive weather data including temperature, humidity, wind, and pressure information.Last updated
- AlicenseAqualityCmaintenanceEnables AI assistants to retrieve real-time weather data and 5-day forecasts for any city using the OpenWeather API, supporting both metric and imperial units.Last updated2MIT
- Alicense-qualityDmaintenanceProvides real-time weather data and forecasts for locations worldwide using the OpenWeatherMap API. It enables AI assistants to retrieve current conditions, temperature, and forecasts through a simple tool-based interface.Last updatedMIT
Related MCP Connectors
WeatherAPI.com MCP — wraps WeatherAPI.com (api.weatherapi.com)
Global weather API: forecasts, historical data, marine, ski, astronomy and timezone.
Global weather via Open-Meteo: forecast, ERA5 archive, marine, air quality, geocoding, elevation.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Abhishek3689/Weather_MCP_Server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server