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 New York?"
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
https://modelcontextprotocol.io/docs/develop/build-server#typescript
Professional TypeScript MCP server that exposes weather tools backed by the US National Weather Service API.
Features
MCP server over stdio
TypeScript strict mode
No required API key
Safe
.envhandlingCLI client for manual testing
Automated MCP smoke tests using a local mock NWS server
Tools:
get-alertsget-forecast
Important:
api.weather.govonly supports locations in the United States and US territories. Forecasts for Italy or other non-US locations will not work with this data source.
Related MCP server: MCP Weather Server
Requirements
Node.js 20 or newer
npm
Check your versions:
node -v
npm -vInstallation
From the project folder:
npm installBuild
npm run buildThis creates compiled JavaScript in build/.
Run the MCP server
npm startThe server communicates over stdio, so when started directly it waits for an MCP client.
Manual CLI testing
First build the project:
npm run buildThen run the included client:
npm run clientExample commands inside the client prompt:
get-alerts { "state": "CA" }
get-forecast { "latitude": 34.05, "longitude": -118.25 }
quitAutomated tests
npm testThe tests do not depend on the live National Weather Service API. They start a local mock weather server and verify that the MCP server lists and executes its tools correctly.
Configuration
No configuration is required for normal use.
Optional environment variables:
NWS_API_BASE=https://api.weather.gov
NWS_USER_AGENT=weather-mcp-server/2.0 your-email@example.comDo not commit .env files. Use .env.example as a template only.
Claude Desktop configuration example
After running npm run build, add something like this to Claude Desktop's MCP configuration, adjusting the path to your local project folder:
{
"mcpServers": {
"weather": {
"command": "node",
"args": [
"C:/Users/torre/Desktop/myWeather/build/server.js"
]
}
}
}Project structure
src/
cli.ts Manual MCP client
nws.ts NWS API helpers and formatting
server.ts MCP server entry point
tests/
mcp-smoke.test.jsAvailable npm scripts
npm run build Compile TypeScript
npm start Start the MCP server
npm run dev Start the server with tsx
npm run client Start the manual CLI client
npm test Build and run automated tests
npm run clean Remove build outputSecurity note
The original project contained a .env file. This version removes it from the distributable project and ignores all .env files by default. If the previous .env contained a real API key, revoke or rotate that key.
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.
Latest Blog Posts
- 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/bennibeni/MCP-weather'
If you have feedback or need assistance with the MCP directory API, please join our Discord server