Weather API: current weather and 48-hour forecast by city

$0.01 per call · failed calls are never charged · no account or subscription: pay per call with a card key or USDC

Current weather by city name, or by latitude and longitude, for any place on Earth: temperature in Celsius, conditions (clear, cloudy, rain, snow), precipitation in mm, wind, humidity, cloud cover and air pressure, plus an hourly forecast for up to 48 hours. Data from the Norwegian Meteorological Institute; city names resolve via Wikidata. Use for travel and event planning, logistics, agriculture and any agent that needs the weather.

When to use it

Guide: Weather forecast API

Run it free (25 free calls) Buy credits by card (from $1) Example result (JSON)

Try it with your own inputs

City or place name, e.g. London or Uppsala (used when lat and lon are not given)

Uses one of your 25 free calls. Nothing is charged, and a call that fails is not counted.

Inputs

NameTypeDescription
citystringCity or place name, e.g. London or Uppsala (used when lat and lon are not given)
latnumberLatitude in decimal degrees, -90 to 90 (with lon, instead of city)
lonnumberLongitude in decimal degrees, -180 to 180 (with lat, instead of city)
hoursintegerHours of hourly forecast to return, 1-48 (default 12; 48 covers tomorrow)

Request

Over HTTP, with a card key from /credits:

curl -H "Authorization: Bearer adt_…" "https://tools.funwords.eu/weather?city=London"

Or one of your 25 free calls, no key:

curl "https://tools.funwords.eu/weather?city=London&trial=1"

Without a key, the same URL answers 402 Payment Required with x402 and MPP terms, so an agent with a wallet pays per call in USDC (Base, Polygon, Arbitrum or Solana over x402; Base or Tempo over MPP) and retries.

Example result

{
  "latitude": 59.33,
  "longitude": 18.07,
  "elevationM": 23,
  "current": {
    "time": "2026-10-13T09:00:00Z",
    "temperatureC": 7.5,
    "conditions": "cloudy",
    "precipitationMm": 0,
    "windSpeedMs": 1.1,
    "windFromDegrees": 317,
    "humidityPercent": 85.9,
    "cloudCoverPercent": 94.6,
    "pressureHpa": 1024.2
  },
  "forecast": [
    {
      "time": "2026-10-13T10:00:00Z",
      "temperatureC": 8.5,
      "conditions": "partlycloudy_day",
      "precipitationMm": 0,
      "windSpeedMs": 1.2,
      "windFromDegrees": 335,
      "humidityPercent": 83.9,
      "cloudCoverPercent": 73,
      "pressureHpa": 1023.8
    }
  ],
  "forecastUpdatedAt": "2026-10-13T08:30:57Z",
  "source": "MET Norway (api.met.no), licensed CC BY 4.0",
  "checkedAt": "2026-10-13T09:12:00.000Z"
}

From an AI agent (MCP)

Add the MCP server to Claude, Cursor or any MCP client. This tool is weather, and the first 25 successful calls are free:

https://tools.funwords.eu/mcp

Questions

Where does the forecast come from?

The Norwegian Meteorological Institute (MET Norway); city names resolve via Wikidata.

Can I use coordinates instead of a city?

Yes, pass lat and lon instead of city.

How do I pay?

Each successful call costs $0.01; failed calls are not charged. The first 25 calls are free. Then pay with card credits (from $1; the key goes in an Authorization header or, for clients that can only fetch a URL, as api_key= in the URL) or per call in USDC over x402 or MPP. No account is needed.

Related tools