API documentation

Welcome to the Meteosource documentation. It’s quick and easy to get weather data from Meteosource up and running on your website or project. If you already have an account, you can check our interactive documentation, where you can try your requests live and see the results immediately.

1. Overview

The Meteosource API allows you to look up the weather anywhere on the globe, returning:
  • Current weather conditions
  • Minute-by-minute forecasts for the next hour
  • Hour-by-hour and day-by-day forecasts out to 30 days
  • Severe weather alerts in the USA, EU, and Canada
  • Hour-by-hour observations going 20 years back

1.1 Weather API Endpoints - Call Types

We provide more API endpoints to retrieve the weather for any location on Earth:
  • Point: Current weather and forecast for single location (specified by GPS or place_id).
  • Map: Receive various PNG weather maps for a given variable and rectangle.
  • Time machine: Returns observed weather conditions for a date in the past.
  • Location endpoints: Endpoints to help you find the location you want and detailed information about it.

1.2 Authentication

You will need your unique API Key to authenticate using the API. You will find this in your Dashboard when you sign up for your account. Keep it safe and secret as this is your unique identification. All requests using your API Key either as a parameter in the URL or an X-API-Key header will count towards your account limit.

1.3 Error codes

If your API request fails, you will receive an error object in JSON format. Each error can be identified with an error code and details about the error that has occurred. You will find a list of all possible errors in the interactive documentation.

Example error response:
{
   "detail":"Neither the \"key\" query parameter nor the X-API-Key header was specified"
}

2. API Endpoints

2.1 Point weather and forecast

Current weather and forecast for single location

Location specification

The location of the weather data is the only parameter that is required and must be specified. There are two ways to do this:

  1. Specify the GPS coordinates of the location using the parameters lat and lon.
  2. OR specify the name of the place using the parameter place_id. To obtain the place_id for the location you want, please use endpoints /find_places_prefix (search by prefix) or /find_places (search by full name).

Note: For mountains, it is usually better to specify the place_id rather than the lat and lon. When you use place_id, you are guaranteed to receive forecasts for the precise elevation of the peak. When you specify the coordinates, the elevation can be less precise.

Sections

The endpoint can return multiple sections of data. To obtain the best performance, we advise only requesting the sections you actually need. The available sections are as follows:

  • Current weather situation
  • Hourly forecast (for 24/48/96/168 hours, depending on the tier)
  • Daily forecast (for 7/10/30 days, depending on the tier)
  • Minutely precipitation forecast (for 60 minutes in the following hour, only for higher tiers)
  • Weather alerts (only for higher tiers)

By default, only the current and hourly sections are returned. The division into daily parts (morning, afternoon and evening) is only available for the first 7 days of the forecast. For details regarding available parameters, see the parameter description below.

Notes
  • For a detailed description of variables (e.g. icons), please consult description of variables.
  • Variables can be instantaneous, averaged, or accumulated over certain time. For example, precipitation forecast provides the precipitation accumulated until the next hour (data with timestamp as 12:00:00 is rain accumulated from 12:00:00 to 13:00:00).
  • Do not make any assumptions about the number and ordering of the variables. New variables and sections may be introduced in the future. Always check the data are present before you try to use them.
  • The response contains an Expires header, which defines the point at which the API response will not change for the same request. We highly recommend using this to avoid unnecessary requests and increase the performance of your app.
  • Meteosource API supports HTTP compression. To enable it, simply add an Accept-Encoding: gzip header to your request.
  • When daylight saving time starts, one hourly record will be missing (typically 2:00:00 AM). When daylight saving time ends, the hourly forecast will contain two records with duplicate times (typically 2:00:00 AM).
  • The detailed description of weather alerts is only available in English. The alert category is translated into selected language.

Example API request

https://www.meteosource.com/api/v1/free/point?place_id=london&sections=all&timezone=UTC&language=en&units=metric&key=YOUR-API-KEY

Parameters

NameDescription
place_id

Identifier of a place. To obtain the place_id for the location you want, please use endpoints /find_places_prefix (search by prefix) or /find_places (search by full name).

lat

Latitude in format 12N, 12.3N, 12.3, or 13S, 13.2S, -13.4

lon

Longitude in format 12E, 12.3E, 12.3, or 13W, 13.2W, -13.4

sections

Sections to be included in the response. You can specify more section by separating the values with a comma. The available values are:

  • current: Current weather situation
  • daily: Forecasts for each whole day, without the daily parts
  • daily-parts: Forecasts for each whole day, morning, afternoon and evening
    • Important: forecast for the morning, afternoon and evening is available only for the first 7 days in the forecast
  • hourly: Forecasts with hourly resolution
  • minutely: Precipitation forecast with 1 minute resolution
  • alerts: The weather alerts
  • all: All sections
timezone

Timezone to be used for the date fields. If not specified, local timezone of the forecast location will be used. The format is according to the tzinfo database, so values like Europe/Prague or UTC can be used. Alternatively you may use the value auto in which case the local timezone of the location is used. The full list of valid timezone strings can be found here.

language

The language of text summaries and place names (variable names are never translated). Available languages are:

  • en: English
  • es: Spanish
  • fr: French
  • de: German
  • pl: Polish
  • pt: Portuguese
  • cs: Czech
units

Unit system to be used. The available values are:

  • auto: Select the system automatically, based on the forecast location.
  • metric: Metric (SI) units (°C, mm/h, m/s, cm, km, hPa).
  • us: Imperial units (°F, in/h, mph, in, mi, Hg).
  • uk: Same as metric, except that visibility is in miles and wind speeds are in mph.
  • ca: Same as metric, except that wind speeds are in km/h and pressure is in kPa.

Response

You will receive a response based on the requested parameters. The example below shows that each response starts with location specification (GPS, elevation, and timezone). Requested sections follow based on your subscription - first, current weather for a given place followed by a minute-by-minute forecast (for paid subscriptions). There is also an hourly section and daily section that is shown either for each whole day or divided into morning/afternoon/evening.

{
    "lat": "51.50853N",
    "lon": "0.12574W",
    "elevation": 25,
    "timezone": "UTC",
    "units": "metric",
    "current": {
        "icon": "partly_sunny",
        "icon_num": 4,
        "summary": "Partly sunny",
        "temperature": 18.8,
        "wind": {
            "speed": 3.7,
            "angle": 17,
            "dir": "NNE"
        },
        "precipitation": {
            "total": 0,
            "type": "none"
        },
        "cloud_cover": 41
    },
    "hourly": {
        "data": [
            {
                "date": "2024-09-16T17:00:00",
                "weather": "partly_sunny",
                "icon": 4,
                "summary": "Partly sunny",
                "temperature": 18.8,
                "wind": {
                    "speed": 3.7,
                    "dir": "NNE",
                    "angle": 17
                },
                "cloud_cover": {
                    "total": 41
                },
                "precipitation": {
                    "total": 0,
                    "type": "none"
                }
            },
            {
                "date": "2024-09-16T18:00:00",
                "weather": "partly_sunny",
                "icon": 4,
                "summary": "Partly sunny",
                "temperature": 17.5,
                "wind": {
                    "speed": 3.6,
                    "dir": "NNE",
                    "angle": 16
                },
                "cloud_cover": {
                    "total": 32
                },
                "precipitation": {
                    "total": 0,
                    "type": "none"
                }
            }
        ]
    },
    "daily": {
        "data": [
            {
                "day": "2024-09-16",
                "weather": "partly_sunny",
                "icon": 4,
                "summary": "Sunny, more clouds in the afternoon. Temperature 12/20 °C.",
                "all_day": {
                    "weather": "partly_sunny",
                    "icon": 4,
                    "temperature": 15.5,
                    "temperature_min": 12,
                    "temperature_max": 19.5,
                    "wind": {
                        "speed": 2.8,
                        "dir": "NNE",
                        "angle": 17
                    },
                    "cloud_cover": {
                        "total": 42
                    },
                    "precipitation": {
                        "total": 0,
                        "type": "none"
                    }
                },
                "morning": null,
                "afternoon": null,
                "evening": null
            },
            {
                "day": "2024-09-17",
                "weather": "partly_sunny",
                "icon": 4,
                "summary": "Partly sunny. Temperature 11/21 °C.",
                "all_day": {
                    "weather": "partly_sunny",
                    "icon": 4,
                    "temperature": 15.2,
                    "temperature_min": 10.5,
                    "temperature_max": 20.8,
                    "wind": {
                        "speed": 3.9,
                        "dir": "NE",
                        "angle": 44
                    },
                    "cloud_cover": {
                        "total": 46
                    },
                    "precipitation": {
                        "total": 0,
                        "type": "none"
                    }
                },
                "morning": null,
                "afternoon": null,
                "evening": null
            }
        ]
    }
}
        

Most of the variables in response are self-explanatory, however, you can find a complete list including icons in our description of variables.

Description of variables

NameDescription
weather

String identifier of the weather icon, e.g. light_rain.

icon

Numeric identifier of the weather icon. The following values can appear:

1 - Not available 2 - Sunny 3 - Mostly sunny
4 - Partly sunny 5 - Mostly cloudy 6 - Cloudy
7 - Overcast 8 - Overcast with low clouds 9 - Fog
10 - Light rain 11 - Rain 12 - Possible rain
13 - Rain shower 14 - Thunderstorm 15 - Local thunderstorms
16 - Light snow 17 - Snow 18 - Possible snow
19 - Snow shower 20 - Rain and snow 21 - Possible rain and snow
22 - Rain and snow 23 - Freezing rain 24 - Possible freezing rain
25 - Hail 26 - Clear (night) 27 - Mostly clear (night)
28 - Partly clear (night) 29 - Mostly cloudy (night) 30 - Cloudy (night)
31 - Overcast with low clouds (night) 32 - Rain shower (night) 33 - Local thunderstorms (night)
34 - Snow shower (night) 35 - Rain and snow (night) 36 - Possible freezing rain (night)

You can download our sets of icons
summary

Short text summary of the weather, e.g. Light rain.

predictability

Weather predictability. Values from 1 (very high predictability) to 5 (very low predictability).

temperature

Temperature 2 metres above ground.

feels_like

Feels like temperature.

soil_temperature

Soil temperature.

wind_chill

Windchill temperature.

dew_point

Dew point temperature.

surface_temperature

Surface air temperature.

wind.speed

Wind speed 10 metres above the ground.

wind.gusts

Wind gust speed.

wind.dir

Wind direction in N, NNE, NE, ..., NNW format.

wind.angle

Wind direction angle in degrees, 180° means wind from the south.

cloud_cover.total

Percentage of sky covered by clouds.

cloud_cover.low

Percentage of sky covered by low clouds.

cloud_cover.middle

Percentage of sky covered by middle clouds.

cloud_cover.high

Percentage of sky covered by high clouds.

pressure

Atmospheric pressure at mean sea level.

precipitation.total

Total precipitation amount accumulated since last hour.

precipitation.type

Precipitation type, may be one of:

  • none, it there is no precipitation
  • rain
  • snow
  • rain_snow
  • ice pellets
  • frozen rain
precipitation.convective

Total convective precipitation amount accumulated since last hour.

precipitation.rainspot

Precipitation in the surrounding of queried location. The data is 7x7 ASCII art string, queried location being in the center. Character # means there is precipitation, . means no precipitation. The distance between neighboring cells is 0.25°.

probability.precipitation

Probability of non-zero precipitation.

probability.storm

Probability of thunderstorm.

probability.freeze

Probability the temperature drops below 0 °C.

cape

Convective available potential energy.

evaporation

Evaporation of liquid water into water vapor.

irradiance

Global downward short-wave radiation flux.

lftx

Surface lifted index.

ozone

Total column of ozone.

uv_index

UV index, values from zero (low risk of harm) to 11+ (extreme risk of harm).

humidity

Relative humidity.

snow_depth

Snow depth.

sunshine_duration

Sunshine duration since start of previous hour.

visibility

Visibility.

astro.sun.rise

Datetime of the sunrise or null during polar day/night.

astro.sun.set

Datetime of the sunset or null during polar day/night.

astro.sun.always_up

True if the sun never sets on given day (polar day), false otherwise.

astro.sun.always_down

True if the sun never rises on given day (polar night), false otherwise.

astro.moon.rise

Datetime of the moonrise or null if the moon does not rise on given day.

astro.moon.set

Datetime of the moonset or null if the moon does not set on given day.

astro.moon.always_up

True if the moon never sets on given day, false otherwise.

astro.moon.always_down

True if the moon never rises on given day, false otherwise.

astro.moon.phase

Number of the moon phase, from 0 to 3 (inclusive), meaning new_moon, first_quarter, full_moon, last_quarter, respectively.

alerts.eventWeather alert event category (translated to selected language).
alerts.onsetDatetime of the alert start.
alerts.expiresDatetime of the alert end.
alerts.senderName of the authority that issued the alert.
alerts.certaintyAlert certainty, one of Extreme, Severe, Moderate, Minor.
alerts.severityAlert severity, one of Observed, Likely, Possible, Unlikely.
alerts.headlineAlert headline (always in English).
alerts.descriptionDetailed alert description (always in English).

2.2 Point Air quality and pollution

Air quality forecast for a single location

Location specification

The location of the weather data is the only parameter that is required and must be specified. There are two ways to do this:

  1. Specify the GPS coordinates of the location using the parameters lat and lon.
  2. OR specify the name of the place using the parameter place_id. To obtain the place_id for the location you want, please use endpoints /find_places_prefix (search by prefix) or /find_places (search by full name).
Notes
  • For a detailed description of variables, please consult description of variables.
  • Do not make any assumptions about the number and ordering of the variables. New variables and sections may be introduced in the future. Always check the data are present before you try to use them.
  • The response contains an Expires header, which defines the point at which the API response will not change for the same request. We highly recommend using this to avoid unnecessary requests and increase the performance of your app.
  • Meteosource API supports HTTP compression. To enable it, simply add an Accept-Encoding: gzip header to your request.
  • When daylight saving time starts, one hourly record will be missing (typically 2:00:00 AM). When daylight saving time ends, the hourly forecast will contain two records with duplicate times (typically 2:00:00 AM).

Example API request

https://www.meteosource.com/api/v1/flexi/air_quality?place_id=london&key=YOUR-API-KEY

Parameters

NameDescription
place_id

Identifier of a place. To obtain the place_id for the location you want, please use endpoints /find_places_prefix (search by prefix) or /find_places (search by full name).

lat

Latitude in format 12N, 12.3N, 12.3, or 13S, 13.2S, -13.4

lon

Longitude in format 12E, 12.3E, 12.3, or 13W, 13.2W, -13.4

timezone

Timezone to be used for the date fields. If not specified, local timezone of the forecast location will be used. The format is according to the tzinfo database, so values like Europe/Prague or UTC can be used. Alternatively you may use the value auto in which case the local timezone of the location is used. The full list of valid timezone strings can be found here.

Response

{
    "lat": "51.50853N",
    "lon": "0.12574W",
    "elevation": 25,
    "timezone": "Europe/London",
    "data": [
        {
            "date": "2024-09-16T18:00:00",
            "aerosol_550": 0.07,
            "air_quality": 1,
            "co_surface": 170.51,
            "dust_550nm": 0,
            "dust_mixing_ratio_05": 1.68e-11,
            "no2_surface": 23.93,
            "no_surface": 0.8,
            "ozone_surface": 88.68,
            "ozone_total": 262.41,
            "pm10": 7.74,
            "pm25": 5.28,
            "so2_surface": 3.24
        },
        {
            "date": "2024-09-16T19:00:00",
            "aerosol_550": 0.06,
            "air_quality": 1,
            "co_surface": 177.74,
            "dust_550nm": 0,
            "dust_mixing_ratio_05": 1.45e-11,
            "no2_surface": 33.23,
            "no_surface": 0.86,
            "ozone_surface": 69.41,
            "ozone_total": 261.31,
            "pm10": 9.15,
            "pm25": 6.24,
            "so2_surface": 3.6
        },
        {
            "date": "2024-09-16T20:00:00",
            "aerosol_550": 0.05,
            "air_quality": 1,
            "co_surface": 177.46,
            "dust_550nm": 0,
            "dust_mixing_ratio_05": 1.37e-11,
            "no2_surface": 33.54,
            "no_surface": 0.58,
            "ozone_surface": 62.53,
            "ozone_total": 260.91,
            "pm10": 10.24,
            "pm25": 6.95,
            "so2_surface": 4.06
        },
        {
            "date": "2024-09-16T21:00:00",
            "aerosol_550": 0.05,
            "air_quality": 1,
            "co_surface": 177.19,
            "dust_550nm": 0,
            "dust_mixing_ratio_05": 1.28e-11,
            "no2_surface": 33.85,
            "no_surface": 0.3,
            "ozone_surface": 55.66,
            "ozone_total": 260.66,
            "pm10": 9.98,
            "pm25": 6.66,
            "so2_surface": 4.52
        },
        {
            "date": "2024-09-16T22:00:00",
            "aerosol_550": 0.04,
            "air_quality": 1,
            "co_surface": 176.91,
            "dust_550nm": 0,
            "dust_mixing_ratio_05": 1.2e-11,
            "no2_surface": 34.16,
            "no_surface": 0.02,
            "ozone_surface": 48.79,
            "ozone_total": 259.56,
            "pm10": 9.49,
            "pm25": 6.17,
            "so2_surface": 4.99
        },
        {
            "date": "2024-09-16T23:00:00",
            "aerosol_550": 0.04,
            "air_quality": 1,
            "co_surface": 172.57,
            "dust_550nm": 0,
            "dust_mixing_ratio_05": 1.21e-11,
            "no2_surface": 30.45,
            "no_surface": 0.02,
            "ozone_surface": 50.16,
            "ozone_total": 257.78,
            "pm10": 9.22,
            "pm25": 5.84,
            "so2_surface": 4.62
        },
        {
            "date": "2024-09-17T00:00:00",
            "aerosol_550": 0.04,
            "air_quality": 1,
            "co_surface": 168.23,
            "dust_550nm": 0,
            "dust_mixing_ratio_05": 1.22e-11,
            "no2_surface": 26.75,
            "no_surface": 0.01,
            "ozone_surface": 51.53,
            "ozone_total": 256.22,
            "pm10": 9.16,
            "pm25": 5.7,
            "so2_surface": 4.25
        },
        {
            "date": "2024-09-17T01:00:00",
            "aerosol_550": 0.04,
            "air_quality": 1,
            "co_surface": 163.89,
            "dust_550nm": 0,
            "dust_mixing_ratio_05": 1.24e-11,
            "no2_surface": 23.04,
            "no_surface": 0,
            "ozone_surface": 52.9,
            "ozone_total": 255.3,
            "pm10": 8.94,
            "pm25": 5.55,
            "so2_surface": 3.88
        }
    ]
}
        

Description of variables

NameDescription
aerosol_550

Total aerosol optical depth at 550 nm.

air_quality

Air quality index. The following values can appear:

  • 1 - Very good
  • 2 - Good
  • 3 - Medium
  • 4 - Poor
  • 5 - Very poor
  • 6 - Extremely poor
co_surface

Carbon monoxide at surface level.

dust_550nm

Dust aerosol optical depth at 550 nm.

dust_mixing_ratio_05

Dust aerosol (0.55 - 0.9 µm) mixing ratio.

no2_surface

Nitrogen dioxide at surface level.

no_surface

Nitrogen monoxide at surface level.

ozone_surface

Ozone.

ozone_total

Total column ozone.

pm10

Particulate matter d < 10 µm (PM10).

pm25

Particulate matter d < 2.5 µm (PM2.5).

so2_surface

Sulphur dioxide at surface level.

2.3 Location: find places

Search for places

You can use this endpoint to obtain place_id of the location you want, to be used in point endpoint. The response also contains detailed information about the location, such as coordinates, timezone and the country the place belongs to.

Unlike the /find_place_prefix endpoint, complete words are required here. You can search for cities, mountains, lakes, countries, ZIP codes, etc. The response can contain multiple places, sorted by relevance. You can then identify the one you want by coordinates, country, or the administrative area.

Example API request

https://www.meteosource.com/api/v1/free/find_places?text=london&key=YOUR-API-KEY

Parameters

NameDescription
text

Place name or ZIP code

language

The language of text summaries and place names (variable names are never translated). Available languages are:

  • en: English
  • es: Spanish
  • fr: French
  • de: German
  • pl: Polish
  • pt: Portuguese
  • cs: Czech
area-

Response

[
    {
        "name": "London",
        "place_id": "london",
        "adm_area1": "England",
        "adm_area2": "Greater London",
        "country": "United Kingdom",
        "lat": "51.50853N",
        "lon": "0.12574W",
        "timezone": "Europe/London",
        "type": "settlement"
    },
    {
        "name": "London",
        "place_id": "london-6058560",
        "adm_area1": "Ontario",
        "adm_area2": null,
        "country": "Canada",
        "lat": "42.98339N",
        "lon": "81.23304W",
        "timezone": "America/Toronto",
        "type": "settlement"
    },
    {
        "name": "London",
        "place_id": "london-4298960",
        "adm_area1": "Kentucky",
        "adm_area2": "Laurel",
        "country": "United States of America",
        "lat": "37.12898N",
        "lon": "84.08326W",
        "timezone": "America/New_York",
        "type": "settlement"
    },
    {
        "name": "City of London",
        "place_id": "city-of-london",
        "adm_area1": "England",
        "adm_area2": "Greater London",
        "country": "United Kingdom",
        "lat": "51.51279N",
        "lon": "0.09184W",
        "timezone": "Europe/London",
        "type": "settlement"
    },
    {
        "name": "London",
        "place_id": "london-4517009",
        "adm_area1": "Ohio",
        "adm_area2": "Madison",
        "country": "United States of America",
        "lat": "39.88645N",
        "lon": "83.44825W",
        "timezone": "America/New_York",
        "type": "settlement"
    },
    {
        "name": "London",
        "place_id": "london-5367815",
        "adm_area1": "California",
        "adm_area2": "Tulare",
        "country": "United States of America",
        "lat": "36.47606N",
        "lon": "119.44318W",
        "timezone": "America/Los_Angeles",
        "type": "settlement"
    },
    {
        "name": "London Village",
        "place_id": "london-village",
        "adm_area1": "Line Islands",
        "adm_area2": "Kiritimati",
        "country": "Kiribati",
        "lat": "1.98487N",
        "lon": "157.47502W",
        "timezone": "Pacific/Kiritimati",
        "type": "settlement"
    },
    {
        "name": "London",
        "place_id": "london-4119617",
        "adm_area1": "Arkansas",
        "adm_area2": "Pope",
        "country": "United States of America",
        "lat": "35.32897N",
        "lon": "93.25296W",
        "timezone": "America/Chicago",
        "type": "settlement"
    },
    {
        "name": "London",
        "place_id": "london-4707414",
        "adm_area1": "Texas",
        "adm_area2": "Kimble",
        "country": "United States of America",
        "lat": "30.67685N",
        "lon": "99.57645W",
        "timezone": "America/Chicago",
        "type": "settlement"
    },
    {
        "name": "East London",
        "place_id": "east-london",
        "adm_area1": "Province of Eastern Cape",
        "adm_area2": "Buffalo City Metropolitan Municipality",
        "country": "South Africa",
        "lat": "33.01529S",
        "lon": "27.91162E",
        "timezone": "Africa/Johannesburg",
        "type": "settlement"
    }
]
        

Description of location endpoints response

Namedescription
nameName of the place, for example London.
place_idUnique identifier of the place, which can be used in /point and /time_machine endpoints, for example london.
adm_area1First-level administrative area (for example a US state), can be null.
adm_area2Second-level administrative area (for example a US county), can be null.
countryName of the country, for example United Kingdom.
latLatitude of the point, for example 23.5S.
lonLongitude of the point, for example 23.5W.
timezoneTimezone of the point in tzinfo format, for example Europe/London.
type The type of the place. May be one of the following:
  • Administrative areas (states, counties, districts...): administrative_area
  • Country: country
  • Political entity different from a country (for example, a dependent teritory): political_entity
  • Villages, towns and cities: settlement
  • Air industry locations: airbase, airfield, heliport, airport, airport_terminal
  • Places related to water: bay, channel, fjord, lake, pond, falls, gulf, harbor, reservoir, sea, dam, cape, island, peninsula
  • Places related to nature: hill, mountain, peak, valley, volcano, canyon, park, reserve, resort, desert

2.4 Location: find places by prefix

Search for places by prefix

You can use this endpoint to obtain place_id of the location you want, to be used in point endpoint. The response also contains detailed information about the location, such as coordinates, timezone and the country the place belongs to.

Unlike the /find_places endpoint, you should only specify the prefix of the place you are looking for. This is particularly useful for autocomplete forms. You can search for cities, mountains, lakes, countries, ZIP codes, etc. The response can contain multiple places, sorted by relevance. You can then identify the one you want by coordinates, country, or the administrative area.

Example API request

https://www.meteosource.com/api/v1/free/find_places_prefix?text=lond&key=YOUR-API-KEY

Parameter

NameDescription
text

Place name or ZIP code

language

The language of text summaries and place names (variable names are never translated). Available languages are:

  • en: English
  • es: Spanish
  • fr: French
  • de: German
  • pl: Polish
  • pt: Portuguese
  • cs: Czech
area-

Response

[
    {
        "name": "London",
        "place_id": "london",
        "adm_area1": "England",
        "adm_area2": "Greater London",
        "country": "United Kingdom",
        "lat": "51.50853N",
        "lon": "0.12574W",
        "timezone": "Europe/London",
        "type": "settlement"
    },
    {
        "name": "Londrina",
        "place_id": "londrina",
        "adm_area1": "Paraná",
        "adm_area2": "Londrina",
        "country": "Brazil",
        "lat": "23.31028S",
        "lon": "51.16278W",
        "timezone": "America/Sao_Paulo",
        "type": "settlement"
    },
    {
        "name": "London",
        "place_id": "london-6058560",
        "adm_area1": "Ontario",
        "adm_area2": null,
        "country": "Canada",
        "lat": "42.98339N",
        "lon": "81.23304W",
        "timezone": "America/Toronto",
        "type": "settlement"
    },
    {
        "name": "Brent",
        "place_id": "brent",
        "adm_area1": "England",
        "adm_area2": "Greater London",
        "country": "United Kingdom",
        "lat": "51.55306N",
        "lon": "0.3023W",
        "timezone": "Europe/London",
        "type": "settlement"
    },
    {
        "name": "Bexley",
        "place_id": "bexley",
        "adm_area1": "England",
        "adm_area2": "Greater London",
        "country": "United Kingdom",
        "lat": "51.44162N",
        "lon": "0.14866E",
        "timezone": "Europe/London",
        "type": "settlement"
    },
    {
        "name": "Sutton",
        "place_id": "sutton",
        "adm_area1": "England",
        "adm_area2": "Greater London",
        "country": "United Kingdom",
        "lat": "51.35N",
        "lon": "0.2W",
        "timezone": "Europe/London",
        "type": "settlement"
    },
    {
        "name": "Lund",
        "place_id": "lund",
        "adm_area1": "Skåne County",
        "adm_area2": "Lund Municipality",
        "country": "Kingdom of Sweden",
        "lat": "55.70584N",
        "lon": "13.19321E",
        "timezone": "Europe/Stockholm",
        "type": "settlement"
    },
    {
        "name": "Londonderry",
        "place_id": "derry",
        "adm_area1": "Northern Ireland",
        "adm_area2": "Derry City and Strabane",
        "country": "United Kingdom",
        "lat": "54.9981N",
        "lon": "7.30934W",
        "timezone": "Europe/London",
        "type": "settlement"
    },
    {
        "name": "Hounslow",
        "place_id": "hounslow",
        "adm_area1": "England",
        "adm_area2": "Greater London",
        "country": "United Kingdom",
        "lat": "51.46839N",
        "lon": "0.36092W",
        "timezone": "Europe/London",
        "type": "settlement"
    },
    {
        "name": "Lawndale",
        "place_id": "lawndale",
        "adm_area1": "California",
        "adm_area2": "Los Angeles",
        "country": "United States of America",
        "lat": "33.88724N",
        "lon": "118.35257W",
        "timezone": "America/Los_Angeles",
        "type": "settlement"
    }
]
        

2.5 Location: find nearest place

Search for nearest place by coordinates

You can use this endpoint to find the nearest place from given coordinates.

Note: If you specify coordinates of a secluded place (e.g. middle of the ocean), the nearest point can be very far from the coordinates.

Example API request

https://www.meteosource.com/api/v1/free/nearest_place?lat=51.5&lon=0&key=YOUR-API-KEY

Parameters

NameDescription
lat

Latitude in format 12N, 12.3N, 12.3, or 13S, 13.2S, -13.4

lon

Longitude in format 12E, 12.3E, 12.3, or 13W, 13.2W, -13.4

language

The language of text summaries and place names (variable names are never translated). Available languages are:

  • en: English
  • es: Spanish
  • fr: French
  • de: German
  • pl: Polish
  • pt: Portuguese
  • cs: Czech

Response

{
    "name": "Blackwall and Cubitt Town",
    "place_id": "blackwall-and-cubitt-town-12048286",
    "adm_area1": "England",
    "adm_area2": "Greater London",
    "country": "United Kingdom",
    "lat": "51.50004N",
    "lon": "0.00656W",
    "timezone": "Europe/London",
    "type": "settlement"
}
        

2.6 Weather maps

PNG weather forecast maps for given area and variable

Area specification

There are two ways to specify geographical area you need for your map:

  1. Specify X and Y coordinates and zoom level Z of desired tile in Google Maps Tile notation.
  2. Specify latitude and longitude bounds of the area you want to cover.
Notes
  • The resulting PNG maps are always in Google Mercator projection (EPSG:3857).
  • As Meteosource only covers areas between latitudes 80° and -80°, you can only request maps within these bounds, when specifying the latitude and longitude boundaries. When specifying the area using Google Maps Tile notation, the regions outside our supported latitudes will be fully transparent.
  • The finest resolution is not available for maps covering very large regions. The resulting map will be automatically downscaled in this case, to guarantee high-speed responses.
  • Weather maps are only supported for forecasts, not for archive data.

Example API request

https://www.meteosource.com/api/v1/flexi/map?min_lat=31&min_lon=-14&max_lat=67&max_lon=56&variable=precipitation&datetime=+12hours&key=YOUR-API-KEY
See code examples of supported integration of map layers

Parameters

NameDescription
tile_x

The X coordinate of Google Maps tile

tile_y

The Y coordinate of Google Maps tile

tile_zoom

The zoom level of Google Maps tile

min_lat

Minimal latitude in format 12N, 12.3N, 12.3, or 13S, 13.2S, -13.2

min_lon

Minimal longitude in format 12E, 12.3E, 12.3, or 13W, 13.2W, -13.2

max_lat

Maximal latitude in format 12N, 12.3N, 12.3, or 13S, 13.2S, -13.2.

max_lon

Maximal longitude in format 12E, 12.3E, 12.3, or 13W, 13.2W, -13.2

variable

Name of the variable for your map. Available values are:

  • temperature: Temperature 2 metres above ground
  • feels_like_temperature: Feels like temperature
  • clouds: Percentage of sky covered by clouds
  • precipitation: Total precipitation amount accumulated since last hour
  • wind_speed: Wind speed 10 metres above the ground
  • wind_gust: Wind gust speed
  • pressure: Atmospheric pressure at mean sea level
  • humidity: Relative humidity
  • wave_height: Wave height
  • wave_period: Wave period
  • sea_temperature: Sea temperature (available only for +-24 hours)
  • air_quality: Air quality index
  • ozone_surface: Ozone at surface level
  • ozone_total: Total column ozone
  • no2: Nitrogen dioxide at surface level
  • pm2.5: Particulate matter d < 2.5 µm (PM2.5)
datetime

There are two ways to specify date and time for your map:

  1. Datetime in YYYY-MM-DDTHH:MM format and UTC timezone, e.g. 2021-08-24T12:00
  2. Offset from current time in [+-]<minutes|hours|days> format, e.g. +10minutes, -2hours or +1days
format

png or pbf

Color maps

Below you will find colormaps for each variable that you can use as a legend for your map. You can also download numerical references for the colormaps.
Variable nameUnitsColor map
temperature °C
feels_like_temperature °C
clouds %
precipitation mm/h
wind_speed m/s
wind_gust m/s
pressure hPa
humidity %
wave_height m
wave_period s
sea_temperature °C
air_quality Index
ozone_surface µg/m3
ozone_total Dobson
no2 µg/m3
pm2.5 µg/m3

Response

2.7 Time machine - past weather

Actual weather data for a single location and day in the past

The output contains actual weather data for each day up to 20 years in the past, and long-term statistics of selected weather variables aggregated over 40 years.

Location specification

The location of the weather data must be specified. There are two ways to do this:

  1. Specify the GPS coordinates of the location using the parameters lat and lon.
  2. OR specify the name of the place using the parameter place_id. To obtain the place_id for the location you want, please use endpoints /find_places_prefix (search by prefix) or /find_places (search by full name).

Note: For mountains, it is usually better to specify the place_id rather than the lat and lon. When you use place_id, you are guaranteed to receive data for the precise elevation of the peak. When you specify the coordinates, the elevation can be less precise.

Example API request

https://www.meteosource.com/api/v1/flexi/time_machine?place_id=london&date=2021-03-15&timezone=UTC&units=auto&key=YOUR-API-KEY

Parameters

NameDescription
place_id

Identifier of a place. To obtain the place_id for the location you want, please use endpoints /find_places_prefix (search by prefix) or /find_places (search by full name).

lat

Latitude in format 12N, 12.3N, 12.3, or 13S, 13.2S, -13.4

lon

Longitude in format 12E, 12.3E, 12.3, or 13W, 13.2W, -13.4

date

The day of the data in the past. Specify in YYYY-MM-DD format, e.g. 2021-08-24.

timezone

Timezone to be used for the date fields. If not specified, local timezone of the location will be used. The format is according to the tzinfo database, so values like Europe/Prague or UTC can be used. Alternatively you may use the value auto in which case the local timezone of the location is used. The full list of valid timezone strings can be found here.

units

Unit system to be used. The available values are:

  • auto: Select the system automatically, based on the forecast location.
  • metric: Metric (SI) units (°C, mm/h, m/s, cm, km, hPa).
  • us: Imperial units (°F, in/h, mph, in, mi, Hg).
  • uk: Same as metric, except that visibility is in miles and wind speeds are in mph.
  • ca: Same as metric, except that wind speeds are in km/h and pressure is in kPa.
language

The language of weather summaries (variable names are never translated). Available languages are:

  • en: English
  • es: Spanish
  • fr: French
  • de: German
  • pl: Polish
  • pt: Portuguese
  • cs: Czech

Response

{
    "lat": "51.50853N",
    "lon": "0.12574W",
    "elevation": 25,
    "timezone": "UTC",
    "units": "uk",
    "data": [
        {
            "date": "2021-03-15T00:00:00",
            "weather": "mostly_cloudy",
            "summary": "Mostly cloudy",
            "icon": 5,
            "temperature": 8.7,
            "feels_like": 4.7,
            "wind_chill": 5.5,
            "soil_temperature": 7.8,
            "dew_point": 6.1,
            "surface_temperature": 6.3,
            "wind": {
                "speed": 13.9,
                "gusts": 27.4,
                "angle": 288,
                "dir": "WNW"
            },
            "cloud_cover": {
                "total": 67,
                "low": 55,
                "middle": 36,
                "high": 20
            },
            "pressure": 1014,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 8,
            "evaporation": 0,
            "irradiance": 0,
            "ozone": 384,
            "humidity": 83
        },
        {
            "date": "2021-03-15T01:00:00",
            "weather": "cloudy",
            "summary": "Cloudy",
            "icon": 6,
            "temperature": 8.5,
            "feels_like": 4.2,
            "wind_chill": 5.2,
            "soil_temperature": 7.9,
            "dew_point": 6.1,
            "surface_temperature": 6.6,
            "wind": {
                "speed": 14.1,
                "gusts": 26.8,
                "angle": 297,
                "dir": "WNW"
            },
            "cloud_cover": {
                "total": 85,
                "low": 58,
                "middle": 72,
                "high": 19
            },
            "pressure": 1015,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 6,
            "evaporation": 0,
            "irradiance": 0,
            "ozone": 383,
            "humidity": 84
        },
        {
            "date": "2021-03-15T02:00:00",
            "weather": "overcast",
            "summary": "Overcast",
            "icon": 7,
            "temperature": 8.4,
            "feels_like": 4.1,
            "wind_chill": 5.2,
            "soil_temperature": 7.9,
            "dew_point": 6,
            "surface_temperature": 6.7,
            "wind": {
                "speed": 13.4,
                "gusts": 26.3,
                "angle": 304,
                "dir": "WNW"
            },
            "cloud_cover": {
                "total": 100,
                "low": 99,
                "middle": 68,
                "high": 18
            },
            "pressure": 1015,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 12,
            "evaporation": 0.01,
            "irradiance": 0,
            "ozone": 384,
            "humidity": 84
        },
        {
            "date": "2021-03-15T03:00:00",
            "weather": "overcast",
            "summary": "Overcast",
            "icon": 7,
            "temperature": 8.4,
            "feels_like": 4.2,
            "wind_chill": 5.3,
            "soil_temperature": 7.8,
            "dew_point": 5.6,
            "surface_temperature": 6.7,
            "wind": {
                "speed": 12.9,
                "gusts": 26.1,
                "angle": 308,
                "dir": "NW"
            },
            "cloud_cover": {
                "total": 98,
                "low": 95,
                "middle": 60,
                "high": 5
            },
            "pressure": 1015,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 12,
            "evaporation": 0.01,
            "irradiance": 0,
            "ozone": 384,
            "humidity": 82
        },
        {
            "date": "2021-03-15T04:00:00",
            "weather": "mostly_cloudy",
            "summary": "Mostly cloudy",
            "icon": 5,
            "temperature": 8,
            "feels_like": 4.1,
            "wind_chill": 4.7,
            "soil_temperature": 7.6,
            "dew_point": 5.4,
            "surface_temperature": 6.3,
            "wind": {
                "speed": 13.1,
                "gusts": 24.9,
                "angle": 313,
                "dir": "NW"
            },
            "cloud_cover": {
                "total": 67,
                "low": 43,
                "middle": 47,
                "high": 2
            },
            "pressure": 1015,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 8,
            "evaporation": 0.01,
            "irradiance": 0,
            "ozone": 384,
            "humidity": 83
        },
        {
            "date": "2021-03-15T05:00:00",
            "weather": "partly_sunny",
            "summary": "Partly sunny",
            "icon": 4,
            "temperature": 8,
            "feels_like": 4.6,
            "wind_chill": 4.9,
            "soil_temperature": 7.5,
            "dew_point": 5.2,
            "surface_temperature": 5.9,
            "wind": {
                "speed": 12.1,
                "gusts": 24.3,
                "angle": 313,
                "dir": "NW"
            },
            "cloud_cover": {
                "total": 55,
                "low": 36,
                "middle": 37,
                "high": 6
            },
            "pressure": 1016,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 4,
            "evaporation": 0.01,
            "irradiance": 0,
            "ozone": 382,
            "humidity": 82
        },
        {
            "date": "2021-03-15T06:00:00",
            "weather": "partly_sunny",
            "summary": "Partly sunny",
            "icon": 4,
            "temperature": 7.7,
            "feels_like": 4.4,
            "wind_chill": 4.7,
            "soil_temperature": 7.3,
            "dew_point": 5.1,
            "surface_temperature": 5.4,
            "wind": {
                "speed": 11.4,
                "gusts": 22.4,
                "angle": 312,
                "dir": "NW"
            },
            "cloud_cover": {
                "total": 61,
                "low": 44,
                "middle": 32,
                "high": 12
            },
            "pressure": 1017,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 2,
            "evaporation": 0.01,
            "irradiance": 16.6,
            "ozone": 380,
            "humidity": 83
        },
        {
            "date": "2021-03-15T07:00:00",
            "weather": "partly_sunny",
            "summary": "Partly sunny",
            "icon": 4,
            "temperature": 7.5,
            "feels_like": 4.2,
            "wind_chill": 4.4,
            "soil_temperature": 7.2,
            "dew_point": 5.1,
            "surface_temperature": 5.9,
            "wind": {
                "speed": 11.5,
                "gusts": 22.4,
                "angle": 315,
                "dir": "NW"
            },
            "cloud_cover": {
                "total": 58,
                "low": 45,
                "middle": 43,
                "high": 2
            },
            "pressure": 1018,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 0,
            "evaporation": 0.04,
            "irradiance": 114,
            "ozone": 379,
            "humidity": 84
        },
        {
            "date": "2021-03-15T08:00:00",
            "weather": "partly_sunny",
            "summary": "Partly sunny",
            "icon": 4,
            "temperature": 8.1,
            "feels_like": 5.1,
            "wind_chill": 5.1,
            "soil_temperature": 7.5,
            "dew_point": 5.4,
            "surface_temperature": 6.9,
            "wind": {
                "speed": 11.5,
                "gusts": 22.7,
                "angle": 318,
                "dir": "NW"
            },
            "cloud_cover": {
                "total": 39,
                "low": 30,
                "middle": 27,
                "high": 0
            },
            "pressure": 1019,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 0,
            "evaporation": 0.09,
            "irradiance": 254.9,
            "ozone": 378,
            "humidity": 83
        },
        {
            "date": "2021-03-15T09:00:00",
            "weather": "partly_sunny",
            "summary": "Partly sunny",
            "icon": 4,
            "temperature": 8.8,
            "feels_like": 6.1,
            "wind_chill": 6.1,
            "soil_temperature": 8,
            "dew_point": 5.8,
            "surface_temperature": 9,
            "wind": {
                "speed": 11,
                "gusts": 26.4,
                "angle": 317,
                "dir": "NW"
            },
            "cloud_cover": {
                "total": 33,
                "low": 22,
                "middle": 6,
                "high": 12
            },
            "pressure": 1019,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 16,
            "evaporation": 0.14,
            "irradiance": 340.3,
            "ozone": 378,
            "humidity": 81
        },
        {
            "date": "2021-03-15T10:00:00",
            "weather": "mostly_cloudy",
            "summary": "Mostly cloudy",
            "icon": 5,
            "temperature": 9.7,
            "feels_like": 6,
            "wind_chill": 7.1,
            "soil_temperature": 8.4,
            "dew_point": 5.2,
            "surface_temperature": 10.6,
            "wind": {
                "speed": 12.2,
                "gusts": 28.9,
                "angle": 325,
                "dir": "NW"
            },
            "cloud_cover": {
                "total": 73,
                "low": 68,
                "middle": 38,
                "high": 7
            },
            "pressure": 1020,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 6,
            "evaporation": 0.18,
            "irradiance": 347.9,
            "ozone": 372,
            "humidity": 73
        },
        {
            "date": "2021-03-15T11:00:00",
            "weather": "mostly_cloudy",
            "summary": "Mostly cloudy",
            "icon": 5,
            "temperature": 10.1,
            "feels_like": 6,
            "wind_chill": 7.4,
            "soil_temperature": 8.9,
            "dew_point": 5.6,
            "surface_temperature": 10.9,
            "wind": {
                "speed": 13.5,
                "gusts": 29.9,
                "angle": 330,
                "dir": "NNW"
            },
            "cloud_cover": {
                "total": 78,
                "low": 37,
                "middle": 43,
                "high": 57
            },
            "pressure": 1020,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 0,
            "evaporation": 0.23,
            "irradiance": 481.1,
            "ozone": 370,
            "humidity": 73
        },
        {
            "date": "2021-03-15T12:00:00",
            "weather": "light_rain",
            "summary": "Light rain",
            "icon": 10,
            "temperature": 10.5,
            "feels_like": 6.2,
            "wind_chill": 7.9,
            "soil_temperature": 9.4,
            "dew_point": 6,
            "surface_temperature": 11,
            "wind": {
                "speed": 13.3,
                "gusts": 24.6,
                "angle": 333,
                "dir": "NNW"
            },
            "cloud_cover": {
                "total": 100,
                "low": 66,
                "middle": 46,
                "high": 100
            },
            "pressure": 1021,
            "precipitation": {
                "total": 0.3,
                "type": "rain"
            },
            "cape": 4,
            "evaporation": 0.27,
            "irradiance": 521.2,
            "ozone": 372,
            "humidity": 73
        },
        {
            "date": "2021-03-15T13:00:00",
            "weather": "overcast",
            "summary": "Overcast",
            "icon": 7,
            "temperature": 10.7,
            "feels_like": 6.6,
            "wind_chill": 8.3,
            "soil_temperature": 10.1,
            "dew_point": 6.1,
            "surface_temperature": 10.7,
            "wind": {
                "speed": 12.5,
                "gusts": 25.1,
                "angle": 333,
                "dir": "NNW"
            },
            "cloud_cover": {
                "total": 100,
                "low": 76,
                "middle": 40,
                "high": 100
            },
            "pressure": 1021,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 6,
            "evaporation": 0.25,
            "irradiance": 443.8,
            "ozone": 374,
            "humidity": 73
        },
        {
            "date": "2021-03-15T14:00:00",
            "weather": "overcast",
            "summary": "Overcast",
            "icon": 7,
            "temperature": 11,
            "feels_like": 6.8,
            "wind_chill": 8.6,
            "soil_temperature": 10.5,
            "dew_point": 5.8,
            "surface_temperature": 12.4,
            "wind": {
                "speed": 12.6,
                "gusts": 25.3,
                "angle": 334,
                "dir": "NNW"
            },
            "cloud_cover": {
                "total": 100,
                "low": 74,
                "middle": 61,
                "high": 100
            },
            "pressure": 1022,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 6,
            "evaporation": 0.23,
            "irradiance": 355.3,
            "ozone": 371,
            "humidity": 70
        },
        {
            "date": "2021-03-15T15:00:00",
            "weather": "overcast",
            "summary": "Overcast",
            "icon": 7,
            "temperature": 11.1,
            "feels_like": 7,
            "wind_chill": 8.8,
            "soil_temperature": 10.6,
            "dew_point": 5.4,
            "surface_temperature": 11.6,
            "wind": {
                "speed": 12.3,
                "gusts": 25.2,
                "angle": 330,
                "dir": "NNW"
            },
            "cloud_cover": {
                "total": 99,
                "low": 34,
                "middle": 52,
                "high": 98
            },
            "pressure": 1022,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 3,
            "evaporation": 0.19,
            "irradiance": 266.9,
            "ozone": 368,
            "humidity": 67
        },
        {
            "date": "2021-03-15T16:00:00",
            "weather": "overcast",
            "summary": "Overcast",
            "icon": 7,
            "temperature": 11.3,
            "feels_like": 7.7,
            "wind_chill": 9.4,
            "soil_temperature": 10.5,
            "dew_point": 4.4,
            "surface_temperature": 10.3,
            "wind": {
                "speed": 9.8,
                "gusts": 22.3,
                "angle": 332,
                "dir": "NNW"
            },
            "cloud_cover": {
                "total": 93,
                "low": 35,
                "middle": 48,
                "high": 89
            },
            "pressure": 1023,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 4,
            "evaporation": 0.11,
            "irradiance": 117,
            "ozone": 367,
            "humidity": 62
        },
        {
            "date": "2021-03-15T17:00:00",
            "weather": "cloudy",
            "summary": "Cloudy",
            "icon": 6,
            "temperature": 10.9,
            "feels_like": 8.1,
            "wind_chill": 9.5,
            "soil_temperature": 10.1,
            "dew_point": 3.8,
            "surface_temperature": 9,
            "wind": {
                "speed": 6.9,
                "gusts": 15.6,
                "angle": 331,
                "dir": "NNW"
            },
            "cloud_cover": {
                "total": 87,
                "low": 26,
                "middle": 38,
                "high": 81
            },
            "pressure": 1023,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 6,
            "evaporation": 0.04,
            "irradiance": 37.8,
            "ozone": 366,
            "humidity": 61
        },
        {
            "date": "2021-03-15T18:00:00",
            "weather": "mostly_cloudy",
            "summary": "Mostly cloudy",
            "icon": 5,
            "temperature": 10,
            "feels_like": 8.2,
            "wind_chill": 9.3,
            "soil_temperature": 9.9,
            "dew_point": 3.4,
            "surface_temperature": 7.2,
            "wind": {
                "speed": 4.2,
                "gusts": 7.7,
                "angle": 312,
                "dir": "NW"
            },
            "cloud_cover": {
                "total": 73,
                "low": 33,
                "middle": 37,
                "high": 46
            },
            "pressure": 1024,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 5,
            "evaporation": 0,
            "irradiance": 0,
            "ozone": 366,
            "humidity": 63
        },
        {
            "date": "2021-03-15T19:00:00",
            "weather": "partly_sunny",
            "summary": "Partly sunny",
            "icon": 4,
            "temperature": 8.6,
            "feels_like": 7.3,
            "wind_chill": 7.6,
            "soil_temperature": 9.6,
            "dew_point": 3.2,
            "surface_temperature": 5.9,
            "wind": {
                "speed": 4.3,
                "gusts": 7.9,
                "angle": 300,
                "dir": "WNW"
            },
            "cloud_cover": {
                "total": 46,
                "low": 25,
                "middle": 27,
                "high": 19
            },
            "pressure": 1025,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 9,
            "evaporation": 0,
            "irradiance": 0,
            "ozone": 366,
            "humidity": 68
        },
        {
            "date": "2021-03-15T20:00:00",
            "weather": "partly_sunny",
            "summary": "Partly sunny",
            "icon": 4,
            "temperature": 8.7,
            "feels_like": 7.1,
            "wind_chill": 7.7,
            "soil_temperature": 9.3,
            "dew_point": 3.2,
            "surface_temperature": 4.8,
            "wind": {
                "speed": 4.5,
                "gusts": 9.3,
                "angle": 301,
                "dir": "WNW"
            },
            "cloud_cover": {
                "total": 60,
                "low": 54,
                "middle": 22,
                "high": 10
            },
            "pressure": 1025,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 9,
            "evaporation": 0.01,
            "irradiance": 0,
            "ozone": 364,
            "humidity": 67
        },
        {
            "date": "2021-03-15T21:00:00",
            "weather": "cloudy",
            "summary": "Cloudy",
            "icon": 6,
            "temperature": 8.3,
            "feels_like": 6,
            "wind_chill": 7,
            "soil_temperature": 9,
            "dew_point": 3.2,
            "surface_temperature": 4.8,
            "wind": {
                "speed": 4.9,
                "gusts": 9.4,
                "angle": 305,
                "dir": "NW"
            },
            "cloud_cover": {
                "total": 84,
                "low": 58,
                "middle": 18,
                "high": 48
            },
            "pressure": 1026,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 5,
            "evaporation": 0.01,
            "irradiance": 0,
            "ozone": 364,
            "humidity": 70
        },
        {
            "date": "2021-03-15T22:00:00",
            "weather": "cloudy",
            "summary": "Cloudy",
            "icon": 6,
            "temperature": 7.7,
            "feels_like": 5.4,
            "wind_chill": 6.4,
            "soil_temperature": 8,
            "dew_point": 3.8,
            "surface_temperature": 4.7,
            "wind": {
                "speed": 4.7,
                "gusts": 9.2,
                "angle": 307,
                "dir": "NW"
            },
            "cloud_cover": {
                "total": 89,
                "low": 27,
                "middle": 81,
                "high": 55
            },
            "pressure": 1026,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 2,
            "evaporation": 0,
            "irradiance": 0,
            "ozone": 364,
            "humidity": 76
        },
        {
            "date": "2021-03-15T23:00:00",
            "weather": "cloudy",
            "summary": "Cloudy",
            "icon": 6,
            "temperature": 7.1,
            "feels_like": 5.1,
            "wind_chill": 5.9,
            "soil_temperature": 7.8,
            "dew_point": 3.9,
            "surface_temperature": 5.1,
            "wind": {
                "speed": 4.2,
                "gusts": 8.9,
                "angle": 312,
                "dir": "NW"
            },
            "cloud_cover": {
                "total": 85,
                "low": 0,
                "middle": 78,
                "high": 41
            },
            "pressure": 1026,
            "precipitation": {
                "total": 0,
                "type": "none"
            },
            "cape": 0,
            "evaporation": 0,
            "irradiance": 0,
            "ozone": 365,
            "humidity": 80
        }
    ],
    "daily": {
        "temperature": 9.1,
        "temperature_min": 7.1,
        "temperature_max": 11.3,
        "feels_like": 5.8,
        "feels_like_min": 4.1,
        "feels_like_max": 8.2,
        "wind_chill": 6.7,
        "wind_chill_min": 4.4,
        "wind_chill_max": 9.5,
        "soil_temperature": 8.7,
        "soil_temperature_min": 7.2,
        "soil_temperature_max": 10.6,
        "dew_point": 4.7,
        "dew_point_min": 2.9,
        "dew_point_max": 5.8,
        "surface_temperature": 7.7,
        "surface_temperature_min": 4.7,
        "surface_temperature_max": 12.4,
        "wind": {
            "speed": 10.2,
            "gusts": 29.9,
            "dir": "NW",
            "angle": 315
        },
        "cloud_cover": {
            "total": 76,
            "low": 47,
            "middle": 44,
            "high": 39
        },
        "pressure": 1020,
        "precipitation": {
            "total": 0.3,
            "type": "rain"
        },
        "humidity": 75
    },
    "statistics": {
        "temperature": {
            "avg": 7.2,
            "avg_min": 4.2,
            "avg_max": 10.5,
            "record_min": 0,
            "record_max": 17
        },
        "wind": {
            "avg_speed": 9.7,
            "avg_angle": 250,
            "avg_dir": "WSW",
            "max_speed": 26.8,
            "max_gust": 56
        },
        "precipitation": {
            "avg": 1.8,
            "probability": 36
        }
    }
}
        

3. Code examples

Looking to include Metesource weather data in your app or service? Our API supports all major programming languages. Find below a series of straightforward code examples in different programming languages, all requesting and printing the latest available weather.

Moreover, you can use our wrapper libraries that will make using our weather data quick and easy to do so.

3.1 Python

        
import requests

parameters = {'key': 'YOUR_API_KEY',
              'place_id': 'london'}

url = "https://www.meteosource.com/api/v1/free/point"

data = requests.get(url, parameters).json()

print('Current temperature in London is {} °C.'.format(data['current']['temperature']))  

        

3.2 PHP

        

$queryString = http_build_query([
  'key' => 'YOUR_API_KEY',
  'place_id' => 'london',
]);

$ch = curl_init(sprintf('%s?%s', 'https://www.meteosource.com/api/v1/free/point', $queryString));
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

$json = curl_exec($ch);
curl_close($ch);

$data = json_decode($json);

echo "Current temperature in London is " . $data->current->temperature . "°C\n";