Access current weather data for any location on Earth including over 200,000 cities! Current weather is frequently updated based on global models and data from more than 40,000 weather stations.
q (optional)
Query Parameter — <strong>City name</strong>. <em>Example: London</em>. You can call by city name, or by city name and country code. The API responds with a list of results that match a searching word. For the query value, type the city name and optionally the country code divided by a comma; use ISO 3166 country codes.
id (optional)
Query Parameter — <strong>City ID</strong>. <em>Example: <code>2172797</code></em>. You can call by city ID. The API responds with the exact result. The List of city IDs can be downloaded <a href="http://bulk.openweathermap.org/sample/">here</a>. You can include multiple cities in parameter — just separate them by commas. The limit of locations is 20. <em>Note: A single ID counts as a one API call. So, if you have city IDs. it's treated as 3 API calls.</em>
lat (optional)
Query Parameter — <strong>Latitude</strong>. <em>Example: 35</em>. The latitude coordinate of the location of your interest. Must use with <code>lon</code>.
lon (optional)
Query Parameter — <strong>Longitude</strong>. <em>Example: 139</em>. Longitude coordinate of the location of your interest. Must use with <code>lat</code>.
zip (optional)
Query Parameter — <strong>Zip code</strong>. Search by zip code. <em>Example: 95050,us</em>. Please note that if the country is not specified, the search uses USA as a default.
units (optional)
Query Parameter — <strong>Units</strong>. <em>Example: imperial</em>. Possible values: <code>standard</code>, <code>metric</code>, and <code>imperial</code>. When you do not use units parameter, format is <code>standard</code> by default.
lang (optional)
Query Parameter — <strong>Language</strong>. <em>Example: en</em>. You can use lang parameter to get the output in your language. We support the following languages that you can use with the corresponded lang values: Arabic - <code>ar</code>, Bulgarian - <code>bg</code>, Catalan - <code>ca</code>, Czech - <code>cz</code>, German - <code>de</code>, Greek - <code>el</code>, English - <code>en</code>, Persian (Farsi) - <code>fa</code>, Finnish - <code>fi</code>, French - <code>fr</code>, Galician - <code>gl</code>, Croatian - <code>hr</code>, Hungarian - <code>hu</code>, Italian - <code>it</code>, Japanese - <code>ja</code>, Korean - <code>kr</code>, Latvian - <code>la</code>, Lithuanian - <code>lt</code>, Macedonian - <code>mk</code>, Dutch - <code>nl</code>, Polish - <code>pl</code>, Portuguese - <code>pt</code>, Romanian - <code>ro</code>, Russian - <code>ru</code>, Swedish - <code>se</code>, Slovak - <code>sk</code>, Slovenian - <code>sl</code>, Spanish - <code>es</code>, Turkish - <code>tr</code>, Ukrainian - <code>ua</code>, Vietnamese - <code>vi</code>, Chinese Simplified - <code>zh_cn</code>, Chinese Traditional - <code>zh_tw</code>.
mode (optional)
Query Parameter — <strong>Mode</strong>. <em>Example: html</em>. Determines format of response. Possible values are <code>xml</code> and <code>html</code>. If mode parameter is empty the format is <code>json</code> by default.
This API call produces the following media types according to the request header;
the media type will be conveyed by the response header.