Real-time Weather

Platform: API iOS Android

Get real-time weather data for 200,000+ cities around the world, including temperature, wind, humidity, pressure, precipitation, visibility, etc.

Note: The real-time data are all near real-time data. Compared with the real physical world, it will be delayed by 5-20 minutes. Please determine the accurate time corresponding to the data according to the obsTime in the data.

Request URL

https://api.qweather.com/v7/weather/now?{QueryParams}

For Free subscription, change the API Host to devapi.qweather.com. See data available for Free subscription.

Request Parameters

All parameters are separated by &. If no optional parameters are set, the default value will be used.

  • key(required)API authentication key, please refer to How To Get Your Key. Support Signature Authentication. Example: key=12334567890ABC
  • location(required)The location to be queried, support LocationID or comma-separated longitude and latitude (decimal, up to 2 decimal places), LocationID can be obtained by GeoAPI. Example: location=101010100 or location=116.41,39.92
  • langMulti-language setting, please see Language to find out how our multi-language works and how to set up.
  • unitSet weather data unit, the available value are unit=m for metric(default) and unit=i for imperial. See more about Unit.

Request Example

Real-time weather for Beijing

curl -L -X GET --compressed 'https://api.qweather.com/v7/weather/now?location=101010100&key=YOUR_KEY'

Response

The response is in JSON format and is Gzip compressed.

{
  "code": "200",
  "updateTime": "2020-06-30T22:00+08:00",
  "fxLink": "http://hfx.link/2ax1",
  "now": {
    "obsTime": "2020-06-30T21:40+08:00",
    "temp": "24",
    "feelsLike": "26",
    "icon": "101",
    "text": "多云",
    "wind360": "123",
    "windDir": "东南风",
    "windScale": "1",
    "windSpeed": "3",
    "humidity": "72",
    "precip": "0.0",
    "pressure": "1003",
    "vis": "16",
    "cloud": "10",
    "dew": "21"
  },
  "refer": {
    "sources": [
      "QWeather",
      "NMC",
      "ECMWF"
    ],
    "license": [
      "QWeather Developers License"
    ]
  }
}
  • code See Status Code
  • updateTime API last update time
  • fxLink Responsive web page of this data, for embedded in website or APP
  • now.obsTime Observation time
  • now.temp temperature
  • now.feelsLike Feels like temperature
  • now.icon Icon code for weather conditions. See also QWeather Icons
  • now.text Weather conditions
  • now.wind360 Wind direction in azimuth degree
  • now.windDir Wind direction
  • now.windScale Wind scale
  • now.windSpeed Wind speed, KM/H
  • now.humidity Relative humidity in percent
  • now.precip Accumulated precipitation in the current hour
  • now.pressure Atmospheric pressure, hPa
  • now.vis Visibility, KM
  • now.cloud Cloud cover in percent, may be null
  • now.dew Dew point temperature, may be null
  • refer.sources Data source and other statements, may be null
  • refer.license Data license, may be null