Use the form above. Parameters, code examples and FAQ are grouped in the documentation section below.
/v1/weather
format=xml (root element <output>).
GET /v1/weather
/v1/weather
/v1/weather?format=xml
{
"tempC": 21.6,
"tempF": 70.9,
"city": "Paris",
"country": "France",
"latitude": 48.8566,
"longitude": 2.3522
}
GET /v1/weather?city=paris
/v1/weather?city=london
/v1/weather?city=london&format=xml
{
"tempC": 9.2,
"tempF": 48.6,
"city": "London",
"country": "United Kingdom",
"latitude": 51.5085,
"longitude": -0.1257
}
Get the current temperature for any city in Celsius and Fahrenheit, geocoded from the city name.
| Endpoint | Returns | Example |
|---|---|---|
/v1/weather | JSON or XML | city=london |
| Name | Type | Default | Description |
|---|---|---|---|
city | string | optional | City name to look up, e.g. london. Leave empty to use the caller's IP location. |
format | string | json | Response format: json or xml. |
curl 'https://freetools.one/v1/weather?city=london'const w = await (await fetch('https://freetools.one/v1/weather?city=paris')).json();
console.log(w.city, w.country, w.tempC + 'C', w.tempF + 'F');import requests
w = requests.get('https://freetools.one/v1/weather', params={'city': 'paris'}).json()
print(w['city'], w['country'], w['tempC'], 'C'){
"tempC": 15.0,
"tempF": 59.0,
"city": "London",
"country": "United Kingdom",
"latitude": 51.50853,
"longitude": -0.12574
}
Yes. /v1/weather?city=london returns the current temperature without any registration, API key or quota signup. It is backed by Open-Meteo.
Both. Every response includes tempC in Celsius and tempF in Fahrenheit, so you never have to convert manually.
The city name is resolved through Open-Meteo's geocoding API, which returns the matched city, country and exact coordinates used for the forecast.
Yes. Add format=xml to get an <output> element instead of JSON.