home / mcp / weather mcp server
Provides weather data from the National Weather Service with alerts and forecasts via MCP over HTTP and dev-ready local startup.
Configuration
View docs{
"mcpServers": {
"azure-samples-remote-mcp-webapp-node": {
"url": "http://localhost:8000"
}
}
}You run a Node.js MCP Weather Server that exposes weather information from the National Weather Service via the MCP protocol. Itβs built with Express.js, serves weather data over HTTP, and is ready to run locally or deployed to Azure App Service for reliable, scalable access in your applications.
You connect to the MCP Weather Server from an MCP client and request weather data such as alerts or forecasts for locations in the United States. Use the server to quickly obtain current alerts for a state or detailed forecast for a place. The built-in test interface at /test helps you verify responses without writing client code, and health information at /health confirms the service is running.
Prerequisites: Node.js 22+ (or Node.js 18+), and npm.
1. Clone the project directory where the MCP Weather Server code resides.
2. Install dependencies.
# Install dependencies in your project directory
npm install3. Start the development server.
npm run dev4. Access the running server locally.
Server: http://localhost:8000
Health Check: http://localhost:8000/health
Test Interface: http://localhost:8000/testIf you want to deploy to Azure App Service, you can use the Azure Developer CLI to provision and deploy the MCP Weather Server. You will authenticate, initialize the project, and deploy in three commands.
# 1. Login to Azure
azd auth login
# 2. Initialize the project
azd init
# 3. Deploy to Azure
azd upAfter deployment, the MCP Weather Server is available at these endpoints on your Azure App Service: Health Check, MCP Capabilities, and the Test Interface.
Health Check: https://<your-app>.azurewebsites.net/health
MCP Capabilities: https://<your-app>.azurewebsites.net/mcp/capabilities
Test Interface: https://<your-app>.azurewebsites.net/testRetrieve weather alerts for a US state. Returns active warnings and advisories you can display to users.
Fetch detailed weather forecast for a location. Use this to present current conditions, hourly or daily forecasts, and related data.