Public API
The WindNerd public API gives open, read-only access to the wind data of every location whose operator chose to publish it. It is built for wind-data aggregators and map builders, and for anyone who wants live wind on their own page.
A location is a spot where a WindNerd station measures the wind (see Devices, locations and accounts). The API is organized around locations rather than hardware: a location keeps its id, history and settings when its station is replaced or moved to another device. The hardware itself is reached through Devices.
- Base URL:
https://api.windnerd.net/v1 - No key, no sign-up for published locations. Requests are rate-limited per IP (see Limits).
- Private locations: an operator can create a key that opens their own location, whatever its visibility (see Private access with a key).
- Devices: an operator can create a key per device to read its state and running mode (see Devices).
- License: CC BY 4.0. You can reuse, redistribute and build on the data if you give credit as described in Attribution.
What you get beyond the usual average, gust and direction:
- a live stream (server-sent events) that pushes 1-minute observations and the 3-second live samples for any set of locations, or all of them;
- temperature, humidity and pressure where the location's station has the sensors;
- history at 1, 5, 10, 15, 30 and 60 minutes, plus 3 h and 6 h buckets aligned to the location's local midnight.
Open the station page on windnerd.net and select the
API tab of the station card. When the location is published, it shows the
ready-to-use /v1/latest URL for that location.
Publishing your station
A location is in the API only while both of these hold:
- its operator set its visibility to Open data in Edit Location, which accepts the CC BY 4.0 license for it. This is the highest visibility level, so every location in the API is also listed on windnerd.net;
- it isn't in maintenance mode, which marks an installation still under test.
A location can therefore leave the API, for example when its operator lowers
its visibility or starts maintenance. As an API user, treat a 404 or a
missing location as "no longer published", not as an error to retry.
Lowering the visibility stops future publishing, but data already shared stays under CC BY 4.0: the license can't be withdrawn from copies already made.
Conventions
| Wind speed | m/s, one decimal |
| Wind direction | degrees the wind comes from, 0–359. null = unknown |
| Temperature | °C |
| Relative humidity | % |
| Pressure | hPa |
| Times | ISO-8601 UTC, e.g. 2026-10-29T14:23:00Z |
wind_avg | scalar mean speed over the period |
wind_max | highest gust in the period |
wind_dir | vector mean direction, weighted by speed |
Atmospheric fields (temperature, relative_humidity, pressure_hpa) are
omitted when the location's station has no sensor or its operator doesn't
share them. Don't expect them to be present.
Every REST response has the same envelope:
{
"license": "CC-BY-4.0",
"source": { "name": "WindNerd", "url": "https://windnerd.net" },
"data": … // array or object, see each endpoint
}
Errors are { "error": "message" } with status 400 (bad query) or 404
(unknown location, or a location that isn't published). 429 means you hit a
rate limit: wait for the number of seconds in the Retry-After header. Errors
are never cached (Cache-Control: private, no-store), so a retry always gets a
fresh answer.
Locations
GET /v1/locations
Lists every published location. The data is metadata only and changes rarely
(cached 5 min), so fetch it occasionally and join on id.
{
"license": "CC-BY-4.0",
"source": { … },
"data": [
{
"id": 69,
"name": "Mont Brumeval — Crête Nord takeoff",
"latitude": 44.9273, // null with longitude when the operator set no map position
"longitude": 5.4418,
"altitude": 1340, // metres, may be null
"country_code": "FR", // may be null
"timezone": "Europe/Paris",
"page_url": "https://windnerd.net/en/brumeval-crete-nord", // may be null
"attribution": {
"text": "Club de vol libre de Brumeval",
"url": "https://cvl-brumeval.example.org"
}
}
]
}
GET /v1/locations/:id
Returns the same object for a single location.
Latest observations
GET /v1/latest
GET /v1/latest?locations=69,195
Returns the latest 10-minute and 1-hour wind for every published location that reported in the last hour, optionally limited to a list of up to 500 ids. This is the endpoint to poll; it is cached 20 s, so polling more often than that gains nothing. To have the data pushed instead, use the stream.
{
"license": "CC-BY-4.0",
"source": { … },
"data": [
{
"location_id": 69,
"date_utc": "2026-10-29T14:23:00Z", // newest 1-minute record
"last_10mn": { "wind_avg": 6.2, "wind_max": 9.1, "wind_dir": 245 },
"last_60mn": { "wind_avg": 5.8, "wind_max": 11.4, "wind_dir": 238 },
"device": { "type": "one_s", "voltage": 3.91 },
"temperature": 14.1, // optional
"relative_humidity": 72, // optional
"pressure_hpa": 1012.4, // optional
"attribution": { "text": "Club de vol libre de Brumeval", "url": "https://cvl-brumeval.example.org" }
}
]
}
- A location that hasn't reported in the last hour is left out.
last_10mnisnullwhen the location reported within the hour but not in the last 10 minutes.- Atmospheric values are the newest reading from the last 20 minutes.
deviceis the station measuring the location now.typeis one ofone,one_s,hq,onspotorwtp, ornullfor a device that is none of these.voltageis its supply voltage in volts from its newest health report of the last hour, ornullwhen there is none.deviceitself isnullif the location has no station.
Recent samples
GET /v1/samples?locations=69,195
Returns the last ~10 minutes of live samples for a list of up to 500 published
ids (required). Use it to fill a chart when you start following locations; the
stream's samples channel then keeps it going. It isn't cached.
{
"license": "CC-BY-4.0",
"source": { … },
"data": [
{ "location_id": 69, "delay": 0,
"samples": [ { "ts": "2026-10-29T14:13:44.020Z", "speed": 5.9, "dir": 251 }, … ],
"attribution": { "text": "…", "url": "…" } }
]
}
- Each entry has the same shape as a stream
samplesevent, with samples in time order, plus the location'sattribution. - A location with no recent samples, or that isn't published, is left out.
- To avoid a gap, open the stream first, then call this, and merge the two by
ts: the first stream batches may also be in this answer.
History
GET /v1/locations/:id/observations?from=…&to=…&period=…
| Parameter | |
|---|---|
from, to | ISO-8601. The range is from < date ≤ to |
period | minutes: 1 (default), 5, 10, 15, 30, 60, 180, 360 |
- Each row is dated at the start of its bucket.
180and360are aligned to the location's local midnight (standard time), so they give morning, afternoon and so on.- A request may cover at most 10 080 periods, for example 7 days at
period=1or 70 days atperiod=10. Page through longer ranges.
{
"license": "CC-BY-4.0",
"source": { … },
"attribution": { "text": "Club de vol libre de Brumeval", "url": "https://cvl-brumeval.example.org" },
"data": [
{ "date_utc": "2026-10-29T14:00:00Z", "wind_avg": 6.1, "wind_max": 9.8, "wind_dir": 241,
"temperature": 14.0, "relative_humidity": 71.2, "pressure_hpa": 1012.5 },
…
]
}
Stream
GET /v1/stream?locations=…&channels=…
A single server-sent events
connection gives you as many locations as you want, pushed as soon as they
arrive. It's plain HTTP: any language can read it, and browsers have
EventSource built in.
| Parameter | |
|---|---|
locations | required: a comma-separated list of up to 500 ids, or * for every published location. * automatically includes locations published after you connected |
channels | optional, both by default. observations: one event per location per minute. samples: the live wind, one point every ~3 s. With * this is a lot of traffic; ask for it only if you use it |
The subscription is the URL. To change it, open a new connection. A malformed
query gets a normal 400 error before the stream starts.
Events. Each event has a name and a JSON data line.
subscribed comes first and confirms what you get:
{ "locations": [69], "rejected": [195], "channels": ["observations", "samples"],
"attributions": { "69": { "text": "Club de vol libre de Brumeval", "url": "https://cvl-brumeval.example.org" } } }
attributions gives the credit of each accepted location, keyed by id, so the
observation and samples events that follow stay small. With * it is
absent: take the attribution from /v1/locations, which also
lists locations published after you connected.
rejected lists the ids that don't exist or aren't published. An explicit list
is checked when you connect, so if one of those locations is published later,
reconnect.
observation arrives each time a location stores a new 1-minute record. It is
the same object as one /v1/latest entry:
{ "location_id": 69, "date_utc": "2026-10-29T14:23:00Z",
"last_10mn": { "wind_avg": 6.2, "wind_max": 9.1, "wind_dir": 245 },
"last_60mn": { "wind_avg": 5.8, "wind_max": 11.4, "wind_dir": 238 } }
samples carries the live wind:
{ "location_id": 69, "delay": 0,
"samples": [ { "ts": "2026-10-29T14:23:41.120Z", "speed": 6.4, "dir": 247 } ] }
speedis the instantaneous wind in m/s.delayis how late the batch is, in seconds.0means real time. Devices in power-saving mode send their samples in batches about a minute late, and those batches havedelay > 0with one point per 3 s.- The stream only carries samples from the moment you connect. For the last
~10 minutes, call
/v1/samplesafter connecting.
ping arrives every 20 s with {}. Ignore it; it keeps proxies from closing
the connection.
Reconnecting. The server asks for a 5 s retry. EventSource reconnects on
its own to the same URL, so the subscription comes back unchanged. With other
clients, reconnect in a loop with a backoff. Either way, fill the gap from
/v1/latest or the history endpoint.
Client examples
curl, to see the raw stream:
$ curl -N 'https://api.windnerd.net/v1/stream?locations=69,195&channels=observations'
retry: 5000
event: subscribed
data: {"locations":[69],"rejected":[195],"channels":["observations"],"attributions":{"69":{…}}}
event: observation
data: {"location_id":69,"date_utc":"2026-10-29T14:23:00Z","last_10mn":{…},"last_60mn":{…}}
event: ping
data: {}
Browser JavaScript, no library:
const es = new EventSource('https://api.windnerd.net/v1/stream?locations=69,195');
es.addEventListener('subscribed', e => console.log('rejected:', JSON.parse(e.data).rejected));
es.addEventListener('observation', e => {
const o = JSON.parse(e.data);
updateMarker(o.location_id, o.last_10mn);
});
es.addEventListener('samples', e => {
const { location_id, samples } = JSON.parse(e.data);
samples.forEach(s => plotPoint(location_id, s.ts, s.speed, s.dir));
});
Node.js, the same API through the eventsource package:
import { EventSource } from 'eventsource';
const es = new EventSource('https://api.windnerd.net/v1/stream?locations=*&channels=observations');
es.addEventListener('observation', e => saveToDb(JSON.parse(e.data)));
Python, with httpx and httpx-sse:
import json, time, httpx
from httpx_sse import connect_sse
URL = "https://api.windnerd.net/v1/stream"
params = {"locations": "*", "channels": "observations"}
while True:
try:
with httpx.Client(timeout=None) as client, \
connect_sse(client, "GET", URL, params=params) as events:
for sse in events.iter_sse():
if sse.event == "observation":
obs = json.loads(sse.data)
print(obs["location_id"], obs["last_10mn"])
except httpx.HTTPError:
pass
time.sleep(5) # then reconnect; fill the gap from /v1/latest
Private access with a key
An operator who keeps a location off the open API can still read it through the API, or give access to someone else, with a private access key for that one location. The key is created in the Private access key card of Edit Location, at any visibility.
Send the key as a header:
Authorization: Bearer 8kQ2v… (32 characters)
or as ?key=8kQ2v… where headers can't be set, as with browser EventSource.
A key changes what a request covers:
| Endpoint | With a key |
|---|---|
GET /v1/locations/:id, …/observations | the key's location works whatever its visibility; other ids behave as without a key |
GET /v1/latest, GET /v1/samples | the key's location only; locations is ignored |
GET /v1/stream | the key's location only; locations is ignored. channels works as usual |
GET /v1/locations | unchanged: the public catalog |
- No license: when the location isn't published,
licenseisnull. The data is the operator's and isn't licensed to anyone. - Errors: an unknown or revoked key gets
401 {"error":"Invalid API key"}. - Rotation: when the operator rotates or revokes the key, the old one stops
working at once, and open streams using it are closed.
EventSourcethen gets a401and stops retrying.
const es = new EventSource('https://api.windnerd.net/v1/stream?key=' + KEY);
es.addEventListener('observation', (e) => show(JSON.parse(e.data)));
Devices
Each device (a WindNerd One, One-S, HQ, OnSpot or WTP device) can have its own device API key, created by its owner from the Device panel of the station's owner view. The key is sent as a header and is the only way into these routes; it names the device, so the URLs carry no id:
Authorization: Bearer 3fJx… (32 characters)
A device key covers the device only: its information, health and running mode.
It doesn't open the data of the device's locations; use a
private access key for that. Responses are
Cache-Control: private, no-store. A missing, unknown or revoked key gets
401.
GET /v1/device
A WindNerd One, One-S or HQ:
{ "device_type": "one_s", "id": 900000,
"online": true, // on its live connection right now; false = eco mode or offline
"firmware_version": "0.6.2",
"last_connection_utc": "2026-11-15T08:02:11Z",
"last_health": { "date_utc": "2026-11-15T09:40:00Z", "voltage": 3.9, "rssi": -71,
"temp_in": 21.5, "uptime": 3600, "free_heap": 81234 },
"locations": [ { "location_id": 69 } ] }
An OnSpot or WTP device:
{ "device_type": "onspot", "id": 10,
"last_health": { "date_utc": "2026-11-15T09:40:00Z", "voltage": 3.7, "rssi": -80, "temp_in": 12.0 },
"locations": [ { "location_id": 195 } ] }
device_type is one of one, one_s, hq, onspot or wtp; null for a
device of unknown type. location_id is the id used by the
data routes. last_health is null until the device has reported once.
GET /v1/device/health?from=…&to=…
Health reports in the range (ISO-8601, at most 7 days), as column arrays:
date_utc, voltage, rssi, temp_in, plus uptime, free_heap and
extra_info for One, One-S and HQ.
GET /v1/device/running-mode (OnSpot future feature)
{ "supported": ["auto", "interval", "hibernate"], "running_mode": { "mode": "interval", "value": 1200 } }
supported lists the running modes this device accepts; it is empty for a
device that takes none (gateways and WTP devices other than OnSpot).
running_mode is the mode set by the device's owner, or null when none is
set. An OnSpot runs in one of:
auto: value0, the device picks its upload interval itself (its default);interval: upload everyvalueseconds, 60–1200, a multiple of 60;hibernate: value0, the device stops measuring and only checks in now and then.
The device receives its running mode in the server's reply to each upload, so a change takes effect at its next upload.
Limits
| REST | about 2 requests/s per IP (burst 20), and 60 requests/min per IP that miss the cache |
| Stream | 5 concurrent connections per IP, at most 500 ids per stream |
| Slow readers | a stream client that stops reading falls behind and is disconnected |
Attribution
The data is under CC BY 4.0. Each location's operator chooses how they
want to be credited (the Credit name and Credit link of
Edit Location), and
attribution already applies their choice. It comes with the data wherever
practical: on each location in /v1/locations, on each entry of /v1/latest
and /v1/samples, once next to data in a location's history, and in the
stream's subscribed event (attributions, explicit lists only).
attribution.text: show it next to the location's data;attribution.url: make that text a link where your medium allows.
Also credit WindNerd as the source, linking to https://windnerd.net. For example:
Wind: Club de vol libre de Brumeval via WindNerd, CC BY 4.0
Each part falls back on its own. When the operator hasn't set a name, text
defaults to "<location name> · WindNerd". When they haven't set a link, url
is the location's page on windnerd.net, or https://windnerd.net for a location
with no page.