Skip to main content
MCP server CX Codex

Openweather — Claude Code MCP server: what it does, how to install

Hands your coding agent current conditions and a 5-day outlook for any city, using the free OpenWeatherMap API.

no license updated 2026-10-29

Open on GitHub

What Openweather does

The agent gets a single tool, weather. Name a city and it comes back with the present conditions and a five-day forecast: temperature, feels-like, pressure, humidity, wind, sunrise and sunset, followed by forecast points by time.

Only city is required. Units (c, f, k) and the response language are optional fields, so the same server answers in Celsius or Fahrenheit. The OpenWeatherMap key goes into OWM_API_KEY; launch the binary without it and the process stops with a fatal message about the unset variable.

Build it yourself with go build -o mcp-weather, which needs Go 1.20+ on the machine. A place the API cannot match comes back as a city not found error, so write city names the way the service recognises them.

What it helps with

  • check conditions in a city without leaving the editor
  • pull a 5-day forecast into a trip plan
  • get temperatures in Fahrenheit or Kelvin for a calculation
  • request conditions in German for a localised report
  • add a weather tool to Cursor or Zed

Example prompts for the agent

  • What's the weather in Berlin right now?
  • Give me the 5-day forecast for Munich in Fahrenheit
  • Check conditions for Berlin, Prague and Vienna in Celsius

How to install Openweather

Install

The MCP registry has no launch command for it: see the repository README

Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more

Questions about Openweather

How do I install Openweather in Claude Code?

Clone the repository with git clone https://github.com/mschneider82/mcp-openweather.git, then cd mcp-openweather and build the binary using go build -o mcp-weather. Put your OpenWeatherMap key into OWM_API_KEY (export OWM_API_KEY="your_api_key_here"). Add an mcpServers entry: the built file path in command, the same key in env.

What does Openweather do?

It exposes one tool, weather, returning current conditions plus a five-day forecast for the city you pass in. The data comes from the OpenWeatherMap API.

What do I need before running it?

Go 1.20+ to build it, and an OpenWeatherMap key. Without a key in OWM_API_KEY the server exits on startup.

Similar MCP servers

All MCP servers for Agent setup: memory, context, orchestration →

Project sponsors

Companies that keep this analytics open