Local Time Conversion Worldwide

Convert a local time in one location to the corresponding local time in another location, or from/to UTC.

Locations can be queried by:

  • Location id (obtained by Places Service).
  • Geographical coordinates (longitude and latitude).

A single query can convert the local time in one location to the local time for up to 200 locations.

The service provides the following data:

  • Coordinated Universal Time (UTC) corresponding to the specified time stamp.
  • Full city name, state (if available), and country.
  • Geographic coordinates.
  • Time zone and offset to UTC at the specified time.

Data coverage

Browse supported locations

List all supported countries

Sample Data

Example Request: https://api.xmltime.com/converttime?fromid=750&toid=146&iso=2011-12-31T00:00:00;version=2&out=json&prettyprint=1&accesskey={KEY}&expires={TIMESTAMP}&signature={SIGNATURE}

{
  "version": 2,
  "utc": {
    "time": {
      "iso": "2011-12-30T13:00:00",
      "datetime": {
        "year": 2011,
        "month": 12,
        "day": 30,
        "hour": 13,
        "minute": 0,
        "second": 0
      }
    }
  },
  "locations": [{
    "id": 750,
    "matches": "source",
    "geo": {
      "name": "Lord Howe Island",
      "state": "Lord Howe Island",
      "country": {
        "id": "au",
        "name": "Australia"
      }
    },
    "time": {
      "iso": "2011-12-31T00:00:00+11:00",
      "datetime": {
        "year": 2011,
        "month": 12,
        "day": 31,
        "hour": 0,
        "minute": 0,
        "second": 0
      },
      "timezone": {
        "offset": "+11:00",
        "zoneabb": "LHDT",
        "zonename": "Lord Howe Daylight Time",
        "zoneoffset": 37800,
        "zonedst": 1800,
        "zonetotaloffset": 39600
      }
    }
  },{
    "id": 146,
    "geo": {
      "name": "Maputo",
      "country": {
        "id": "mz",
        "name": "Mozambique"
      }
    },
    "time": {
      "iso": "2011-12-30T15:00:00+02:00",
      "datetime": {
        "year": 2011,
        "month": 12,
        "day": 30,
        "hour": 15,
        "minute": 0,
        "second": 0
      },
      "timezone": {
        "offset": "+02:00",
        "zoneabb": "CAT",
        "zonename": "Central Africa Time",
        "zoneoffset": 7200,
        "zonedst": 0,
        "zonetotaloffset": 7200
      }
    }
  }]
}

Example Request: https://api.xmltime.com/converttime?fromid=australia/lord-howe-island&toid=mozamique/maputo&iso=2011-12-31T00:00:00;version=2&out=xml&prettyprint=1&accesskey={KEY}&expires={TIMESTAMP}&signature={SIGNATURE}

<?xml version="1.0" encoding="UTF-8"?>
<data version="2">
  <utc>
    <time iso="2011-12-30T13:00:00">
      <datetime>
        <year>2011</year>
        <month>12</month>
        <day>30</day>
        <hour>13</hour>
        <minute>00</minute>
        <second>00</second>
      </datetime>
    </time>
  </utc>
  <location id="750" matches="source">
    <geo>
      <name>Lord Howe Island</name>
      <state>Lord Howe Island</state>
      <country id="au">Australia</country>
    </geo>
    <time iso="2011-12-31T00:00:00+11:00">
      <datetime>
        <year>2011</year>
        <month>12</month>
        <day>31</day>
        <hour>00</hour>
        <minute>00</minute>
        <second>00</second>
      </datetime>
      <timezone offset="+11:00">
        <zoneabb>LHDT</zoneabb>
        <zonename>Lord Howe Daylight Time</zonename>
        <zoneoffset>37800</zoneoffset>
        <zonedst>1800</zonedst>
        <zonetotaloffset>39600</zonetotaloffset>
      </timezone>
    </time>
  </location>
  <location id="146">
    <geo>
      <name>Maputo</name>
      <country id="mz">Mozambique</country>
    </geo>
    <time iso="2011-12-30T15:00:00+02:00">
      <datetime>
        <year>2011</year>
        <month>12</month>
        <day>30</day>
        <hour>15</hour>
        <minute>00</minute>
        <second>00</second>
      </datetime>
      <timezone offset="+02:00">
        <zoneabb>CAT</zoneabb>
        <zonename>Central Africa Time</zonename>
        <zoneoffset>7200</zoneoffset>
        <zonedst>0</zonedst>
        <zonetotaloffset>7200</zonetotaloffset>
      </timezone>
    </time>
  </location>
</data>
Terms & Conditions Copyright © Time and Date AS
All data supplied by timeanddate.com