Skip to main content
Glama
Weather MCP Server

Weather MCP Server

Weather MCP Server

An MCP (Model Context Protocol) server that provides weather forecasts using OpenStreetMap Nominatim for geocoding and the National Weather Service (Weather.gov) API for forecast data.

Features

  • Single tool: get_weather_forecast - Get weather forecasts for any city, state, or address

  • Uses OpenStreetMap Nominatim for free geocoding (no API key required)

  • Uses Weather.gov API for accurate, free weather data (US locations only)

  • Returns detailed forecast periods with temperature, wind, and conditions

Related MCP server: Weather MCP Server

Installation

  1. Install dependencies:

npm install
  1. Build the project:

npm run build

Configuration

Add this server to your Claude Desktop config file:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "weather": {
      "command": "node",
      "args": ["/Users/atharvawadekar/Desktop/Projects/WeatherMCP/dist/index.js"]
    }
  }
}

Usage

Once configured, you can ask Claude:

  • "What's the weather in Seattle?"

  • "Get me the forecast for Miami, FL"

  • "What's the weather like in Portland, Oregon?"

  • "Tell me the weather for 1600 Pennsylvania Ave, Washington DC"

Tool Details

get_weather_forecast

Input:

  • location (string): City name, state, or full address

Output:

  • Location name and coordinates

  • NWS forecast office

  • Multiple forecast periods with:

    • Period name (Today, Tonight, Tomorrow, etc.)

    • Temperature

    • Wind speed and direction

    • Short and detailed forecast descriptions

How It Works

  1. Takes a location string (city, state, or address)

  2. Geocodes it using OpenStreetMap Nominatim to get latitude/longitude

  3. Calls Weather.gov /points/{lat},{lon} to get grid data

  4. Fetches the forecast from the returned forecast URL

  5. Formats and returns the weather data

Limitations

  • US locations only: Weather.gov only provides data for US locations

  • Rate limits: Be respectful of Nominatim's usage policy (max 1 request/second)

  • Geocoding accuracy: Results depend on OpenStreetMap's geocoding quality

Development

Run in development mode with auto-rebuild:

npm run dev

License

MIT

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      D
      maintenance
      Enables AI assistants to access real-time US weather forecasts and alerts through the National Weather Service API.
      2
      13 npm
      MIT
    • -
      license
      Not graded
      quality
      Not graded
      maintenance
      Provides weather forecast data from the US National Weather Service API through MCP tools. Enables users to get detailed weather forecasts by ZIP code or coordinates using natural language queries.
      -
    • F
      license
      Not graded
      quality
      D
      maintenance
      Enables users to get weather forecasts and alerts for any US city and state through natural language queries using the National Weather Service API.
      -
    • A
      license
      Not graded
      quality
      D
      maintenance
      Provides weather forecasts and alerts for US locations via the National Weather Service API, enabling AI assistants to deliver real-time weather information.
      28 npm
      ISC