Historical Weather API (Sub-Hourly)

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

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

  • Trial Plan: Max 7 days of data per API call.
  • Starter/Developer Plan: No Access.
  • *Advanced plan: 31 days of data per API call.

*Up to 1 month of data can be requested per API call, however, requests that exceed 1 day will count as multiple requests against the plan daily quota. Example: 31 days = 31 requests, 14 days = 14 requests, 2 days = 2 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] (REQUIRED)
end_date=[YYYY-MM-DD] (REQUIRED)
tz=[utc OR local](optional)
  • utc - [DEFAULT] Assumes UTC for start_date, end_date
  • local - Assumes LOCAL time for start_date, end_date
  • en - [DEFAULT] English
  • M - [DEFAULT] Metric (Celcius, 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=2021-09-20&end_date=2021-09-21
Get history by city name city, state(optional), country (optional), start_date, end_date &city=Raleigh,NC&start_date=2021-09-20&end_date=2021-09-21
Get history by postal code postal_code, country (optional), start_date, end_date &postal_code=27601&country=US&start_date=2021-09-20&end_date=2021-09-21
Get history by city id city_id, start_date, end_date &city_id=8953360&start_date=2021-09-20&end_date=2021-09-21
Get history by ICAO or station id station, start_date, end_date &station=KRDU&start_date=2021-09-20&end_date=2021-09-21

Example Request:


Example Response (JSON):

                        "description":"Overcast clouds"
                        "description":"Broken clouds"
                  }, ...


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: Nearest station. [Deprecated]
  • sources: List of stations used in response.
  • data: [
    • ts: Timestamp (Unix Timestamp).
    • timestamp_local: Timestamp at Local time.
    • timestamp_utc: Timestamp at UTC time.
    • pres: Pressure (MB).
    • slp: Sea level pressure (MB).
    • temp: Temperature (default Celcius).
    • app_temp: Apparent/"Feels Like" temperature (default Celcius).
    • wind_spd: Wind speed (Default m/s).
    • wind_dir: Wind direction (degrees).
    • rh: Relative humidity (%).
    • dewpt: Dew point (default Celcius).
    • clouds:Cloud coverage (%).
    • 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+).
  • ... ]