World Time API for Developers
The simplest free JSON API to get the current time, timezone, daylight saving (DST) data, and IP geolocation for any location on Earth.
Handling date and time programming is difficult. Dealing with timezones, DST transitions, and geo-IP lookups requires heavy libraries. Our World Time API solves this by doing the math on our servers and returning a clean, lightweight JSON response. Perfect for IoT devices, dashboards, smart mirrors, and web applications.
- ✅ 100% Free World Time API for personal and commercial projects.
- ✅ No API Key required – just start fetching.
- ✅ CORS Enabled – Access directly from frontend JavaScript frameworks (React, Vue, etc.).
- ✅ Accurate Atomic Time synchronized continuously.
❤️ Support This Free API (Required)
We provide this service completely free of charge. In exchange, we kindly ask that you provide a link back to Time.Now on your website footer, README, or application "About" screen.
Copy this snippet:
<a href="https://time.now">World Time API by Time.Now</a>
Base URL
All API requests should be made via HTTPS to:
https://time.now/developer/api
API Endpoints
GET /timezone/:area/:location
Request the current time object for a specific IANA timezone.
Example Request:
GET https://time.now/developer/api/timezone/Europe/London
Example JSON Response:
{
"abbreviation": "BST",
"datetime": "2023-10-05T14:30:00.123456+01:00",
"day_of_week": 4,
"day_of_year": 278,
"dst": true,
"dst_offset": 3600,
"timezone": "Europe/London",
"unixtime": 1696512600,
"utc_datetime": "2023-10-05T13:30:00.123456Z",
"utc_offset": "+01:00",
"week_number": 40
}
GET /ip
Get the current time based on the public IP address of the requester. This is useful for auto-detecting a user's local time without asking for location permissions.
Auto-Detect IP Request:
GET https://time.now/developer/api/ip
Specific IP Lookup Request:
GET https://time.now/developer/api/ip/8.8.8.8
GET /timezone
Returns a list of all available valid IANA timezone strings as a JSON array.
GET https://time.now/developer/api/timezone
JSON Response Schema
The API returns a JSON object with the following fields:
| Key | Type | Description |
|---|---|---|
timezone | String | The IANA timezone name (e.g., America/New_York). |
datetime | String | Current local time in ISO8601 format with offset. |
unixtime | Integer | Seconds since the Unix Epoch (UTC). |
utc_offset | String | The offset from UTC as a string (e.g., +05:30). |
abbreviation | String | Short timezone name (e.g., EST, JST, CST). |
dst | Boolean | True if Daylight Saving Time is currently active. |
dst_offset | Integer | Seconds added due to DST (usually 0 or 3600). |
client_ip | String | The IP address used for the geo-lookup. |
Code Examples
JavaScript (Fetch)
fetch('https://time.now/developer/api/ip')
.then(response => response.json())
.then(data => {
console.log('Current time:', data.datetime);
console.log('Timezone:', data.timezone);
});
Python (Requests)
import requests
response = requests.get('https://time.now/developer/api/timezone/Asia/Tokyo')
data = response.json()
print(f"Current time in Tokyo: {data['datetime']}")
cURL
curl "https://time.now/developer/api/timezone/Europe/Paris"