Standard APIGET /v1/timezone

Timezone API

Instantly resolve the timezone and current local time for any location on Earth.

A single call returns the IANA timezone identifier (e.g. America/New_York), the current local time, and the UTC offset for any city, coordinate pair, postal code, or airport code. No separate geocoding step required — just pass the same q parameter you use across every other WeatherAI.io endpoint.

What You Get with the Timezone API

IANA timezone IDs

Returns standardised timezone names (e.g. Europe/London) compatible with every major programming language and library.

Current local time included

The live local time is returned alongside the timezone, saving you a client-side calculation.

Same query syntax as all other APIs

Use city name, lat/lon, postcode, IP address, or IATA code — no separate geocoding service needed.

DST handled automatically

UTC offsets account for daylight saving time based on the actual current date — no seasonal logic to maintain.

Lightweight response

A tiny, fast response — ideal for serverless functions and mobile apps where bandwidth matters.

Free on Standard tier

Included in your 1,000 free daily calls — no extra cost even for high-volume timezone lookups.

Who Uses This API

From startups to enterprise teams, the Timezone API powers a wide range of real-world applications.

Scheduling & calendar apps

Resolve the correct timezone for a meeting or reminder location without integrating a separate geocoding service.

Flight & travel trackers

Display departure and arrival times in the correct local timezone, automatically adjusted for DST.

Global SaaS platforms

Set user timezones at registration by resolving their IP address — no timezone picker needed.

Log & event timestamp normalisation

Convert server-side UTC timestamps to meaningful local times for distributed systems and audit trails.

Request Parameters

ParameterTypeRequiredDescriptionExample
qstringRequiredLocation — city, lat/lon, postcode, IP, or IATA codeSydney

Authenticate every request with the X-API-Key header.

Code Example

Request

cURL
curl "https://api.weatherai.io/v1/timezone?q=Sydney" \
  -H "X-API-Key: your-api-key"

Response

200 OKapplication/json
{
  "name": "Sydney",
  "region": "New South Wales",
  "country": "Australia",
  "lat": -33.87,
  "lon": 151.21,
  "timezone": "Australia/Sydney",
  "localtime": "2024-04-25 09:30",
  "localtime_epoch": 1714005000,
  "utc_offset": "+10:00"
}

Response Fields

FieldTypeDescription
namestringLocation name
regionstringRegion or state
countrystringCountry name
lat / lonnumberCoordinates
timezonestringIANA timezone identifier (e.g. Australia/Sydney)
localtimestringCurrent local time (YYYY-MM-DD HH:MM)
localtime_epochintegerCurrent local time as Unix timestamp
utc_offsetstringUTC offset including DST (e.g. +11:00)

Start Using the Timezone API Today

Create a free account and get your API key in under a minute. 1,000 free calls per day. No credit card required.

Get Your Free API Key