Sub-Hourly Historical Weather

This API returns historical weather data from our network stations reporting sub-hourly weather data as well as radar, satellite, and weather re-analyses such as the ERA5. This is historical data at 15 minute intervals, and a request will return data from all data sources within ~15km of the requested point. This API returns sub-hourly (15 minute interval) data.

The following per API request limitations apply (See: pricing):

  • Trial Plan: 1 day per API request.
  • *Plus / Business / Enterprise plans: 5 days of data per API request.
  • Other plan(s): No access

*For convenience, up to 1 month of data can be requested per API request. However, requests that exceed 5 days will count as multiple requests against the plan daily quota. Example: 30 days = 6 requests, 14 days = 3 requests, etc.

All parameters should be supplied to the Weather API as query string parameters.

Base URL

HTTP: http://api.weatherbit.io/v2.0/history/subhourly
HTTPS: https://api.weatherbit.io/v2.0/history/subhourly
Supported Methods: GET

Request Parameters

key=[key] (REQUIRED)
  • key - Your API Key.
start_date=[YYYY-MM-DD OR YYYY-MM-DD:HH] (REQUIRED)
end_date=[YYYY-MM-DD OR YYYY-MM-DD:HH] (REQUIRED)
tz=[utc OR local](optional)
  • utc - [DEFAULT] Assumes UTC for start_date, end_date
  • local - Assumes LOCAL time for start_date, end_date
lang=[language](optional)
  • en - [DEFAULT] English
units=[units](optional)
  • M - [DEFAULT] Metric (Celsius, m/s, mm)
  • S - Scientific (Kelvin, m/s, mm)
  • I - Fahrenheit (F, mph, in)

API Endpoints

Description Required Parameters Example(s)
Get history by lat/lon (Recommended) lat, lon, start_date, end_date &lat=38.123&lon=-78.543&start_date=2024-10-05&end_date=2024-10-06
Get history by city name city, state(optional), country (optional), start_date, end_date &city=Raleigh,NC&start_date=2024-10-05&end_date=2024-10-06
Get history by postal code postal_code, country (optional), start_date, end_date &postal_code=27601&country=US&start_date=2024-10-05&end_date=2024-10-06
Get history by city id city_id, start_date, end_date &city_id=8953360&start_date=2024-10-05&end_date=2024-10-06
Get history by ICAO or station id [Use with Caution] station, start_date, end_date &station=KRDU&start_date=2024-10-05&end_date=2024-10-06

Example Request:

https://api.weatherbit.io/v2.0/history/subhourly?lat=35.775&lon=-78.638&start_date=2024-10-05&end_date=2024-10-06&tz=local&key=API_KEY

Example Response (JSON):


            {
               "timezone":"America\/New_York",
               "state_code":"NC",
               "country_code":"US",
               "lat":35.775,
               "lon":-78.638,
               "city_name":"Raleigh",
               "station_id":"723060-13722",
               "city_id":"4487042",
               "sources":["723060-13722","imerg","merra2","era5","modis"],
               "data":[
                  {
                     "pres":1015,
                     "slp":1021,
                     "dewpt":23.1,
                     "precip_rate":0,
                     "wind_dir":210,
                     "weather":{
                        "icon":"c04n",
                        "code":804,
                        "description":"Overcast clouds"
                     },
                     "wind_spd":4.09,
                     "wind_gust_spd": 8,
                     "timestamp_local":"2021-06-10T20:00:00",
                     "timestamp_utc":"2021-06-11T00:00:00",
                     "revision_status":"final",
                     "snow_rate":0,
                     "app_temp":24.9,
                     "vis":11,
                     "temp":23.9,
                     "rh":96,
                     "clouds":78,
                     "uv":0,
                     "ghi":0,
                     "dhi":0,
                     "dni":0,
                     "solar_rad":0,
                     "elev_angle":0,
                     "azimuth":0,
                     "ts":1623369600
                  },
                  {
                     "pres":1015,
                     "slp":1021,
                     "dewpt":22.7,
                     "precip_rate":0,
                     "wind_dir":195,
                     "weather":{
                        "icon":"c03n",
                        "code":803,
                        "description":"Broken clouds"
                     },
                     "pod":"n",
                     "wind_spd":3.76,
                     "wind_gust_spd": 8.2,
                     "timestamp_local":"2021-06-10T20:15:00",
                     "timestamp_utc":"2021-06-11T00:15:00",
                     "revision_status":"final",
                     "snow_rate":0,
                     "app_temp":24.6,
                     "vis":13,
                     "temp":23.7,
                     "rh":95.25,
                     "clouds":68,
                     "uv":0,
                     "ghi":0,
                     "dhi":0,
                     "dni":0,
                     "solar_rad":0,
                     "elev_angle":0,
                     "azimuth":0,
                     "ts":1623370500
                  }, ...
                ]
            }


        

Field Decriptions:

  • lat: Latitude (Degrees).
  • lon: Longitude (Degrees).
  • timezone: Local IANA Timezone.
  • city_name: City name.
  • city_id: City ID.
  • country_code: Country abbreviation.
  • state_code: State abbreviation/code.
  • station_id: [DEPRECATED] Nearest station.
  • sources: List of data sources used in response.
  • data: [
    • ts: Timestamp (Unix Timestamp).
    • timestamp_local: Timestamp at Local time.
    • timestamp_utc: Timestamp at UTC time.
    • revision_status Data revision status - interim (subject to revisions) or final.
    • pres: Pressure (MB).
    • slp: Sea level pressure (MB).
    • temp: Temperature (default Celsius).
    • app_temp: Apparent/"Feels Like" temperature (default Celsius).
    • wind_spd: Wind speed (Default m/s).
    • wind_gust_spd: Wind gust speed (Default m/s).
    • wind_dir: Wind direction (degrees).
    • rh: Relative humidity (%).
    • dewpt: Dew point (default Celsius).
    • clouds:Cloud coverage (%).
    • pod: Part of the day (d = day / n = night).
    • weather: {
      • icon: Weather icon code.
      • code: Weather code.
      • description: Text weather description.
      }
    • vis: Visibility (default KM).
    • precip_rate: Liquid equivalent precipitation rate (default mm/hr).
    • snow_rate: Snowfall rate (default mm/hr).
    • dhi: Diffuse horizontal solar irradiance (W/m^2) [Clear Sky]
    • dni: Direct normal solar irradiance (W/m^2) [Clear Sky]
    • ghi: Global horizontal solar irradiance (W/m^2) [Clear Sky]
    • solar_rad: Estimated Solar Radiation (W/m^2).
    • elev_angle: Solar elevation angle (degrees).
    • azimuth: Solar azimuth angle (degrees).
    • uv: UV Index (0-11+).
  • ... ]