Hourly Data

This endpoint provides historical hourly observations for a particular weather station. Furthermore, gaps in the time series can be filled in with statistically optimized model data. The data provided through this endpoint is aggregated from multiple governmental interfaces.

Hourly observations are coming in with an offset of about two to three hours. However, some data might be added multiple days or even months later, depending on how the different weather services are updating their datasets.

Hourly data can be queried for a maximum of 10 days per request.

Endpoint

Hourly data is provided through this endpoint:

GET https://api.meteostat.net/v2/stations/hourly

Parameters

When calling this endpoint please refer to the following parameters.

ParameterDescriptionData TypeRequiredDefault
stationThe weather station IDStringYesundefined
startThe start date of the query (format: YYYY-MM-DD)StringYesundefined
endThe end date of the query (format: YYYY-MM-DD)StringYesundefined
tzThe time zone according to the tz databaseStringNoUTC
modelA boolean parameter that specifies whether missing observations should be substituted with statistically optimized model dataIntegerNo0

Response

The response body includes the following properties.

ParameterDescriptionData Type
timeUTC time stamp (format: YYYY-MM-DD hh:mm:ss)String
time_localLocal time stamp (format: YYYY-MM-DD hh:mm:ss); only provided if tz is setString
tempThe air temperature in °CFloat
dwptThe dew point in °CFloat
rhumThe relative humidity in percent (%)Integer
prcpThe one hour precipitation total in mmFloat
snowThe snow depth in mmInteger
wdirThe wind direction in degrees (°)Integer
wspdThe average wind speed in km/hFloat
wpgtThe peak wind gust in km/hFloat
presThe sea-level air pressure in hPa Float
tsunThe one hour sunshine total in minutes (m)Integer
cocoThe weather condition codeInteger

More information on the data formats and weather condition codes is available here.

Examples

The following example requires the cURL command-line interface. Alternatively, you can use an API client like Postman.

curl --header "x-api-key: {key}" "https://api.meteostat.net/v2/stations/hourly?station=10637&start=2020-02-01&end=2020-02-04"

Please replace {key} with your personal API key.

Data Response

The data output returns one object per hour. Have a look at this example:

{
	"time": "2019-12-31 23:00:00",
	"time_local": "2020-01-01 00:00:00",
	"temp": 1.6,
	"dwpt": 0.1,
	"rhum": 90,
	"prcp": 0,
	"snow": 0,
	"wdir": 300,
	"wspd": 5,
	"wpgt": 10,
	"pres": 1036.4,
	"tsun": 0,
	"coco": 4
}