CalcOpenly
English

Unix timestamp converter

Unix timestamp converter: epoch seconds, milliseconds, microseconds or nanoseconds to an ISO 8601 UTC date and local time, and dates back to epoch time.

Drafted with AI writing toolsUpdated Checked examples: 8

Digits (optionally negative or with a decimal part), an ISO 8601 date-time such as 2026-01-15T09:00:00Z, or “now”.
Try
ISO 8601 (UTC)
2026-11-12T18:16:57.986Z
ISO 8601 (UTC): 2026-11-12T18:16:57.986Z
Local time in the chosen zone
2026-11-12 18:16:57.986 (UTC+00:00)
Unix seconds
1794507417.986
Milliseconds
1794507417986
Microseconds
1794507417986000
Nanoseconds
1794507417986000000
Day of the week (UTC)
Thursday
Read as
current time
Relative to now
Now

Unix time 1794507417.986 is 2026-11-12T18:16:57.986Z, a Thursday, which is the current time.

Where this instant sits

20,769 days from the epoch: 1 Jan 1970 to 13 Nov 202620,769 days from the epochEpoch: 1970-01-01T00:00ZEpoch1970-01-01T00:00ZThis timestamp: 2026-11-12T18:16:57.986ZThis timestamp2026-11-12T18:16:57.986ZNow: 13 Nov 2026Now13 Nov 2026
How it's calculated S
  1. Days and seconds since the epoch

    1794507417=86400×20769+658171794507417 = 86400 \times 20769 + 65817

    Unix time ignores leap seconds: every day has exactly 86,400 seconds.

  2. Day number to calendar date

    Day 20769 after 1 January 1970 is Thu 12 Nov 2026; 65817 s after midnight is 18:16:57 UTC.

  3. Shift to the chosen zone

    UTC is UTC+00:00 at that instant, so the local time is 2026-11-12 18:16:57.986 (Thu 12 Nov 2026).

About the Unix timestamp converter

A Unix timestamp counts the seconds since 00:00:00 UTC on 1 January 1970, the Unix epoch, with every day counted as exactly 86,400 seconds. The converter splits the count into whole days and seconds of the day, turns the day number into a calendar date, then applies the chosen zone's offset from the IANA time zone database. Date to timestamp runs the same steps backwards.

Developers use it to read log lines, database columns and API fields. With the unit left on automatic, up to 11 digits are read as seconds, 12 to 14 as milliseconds, 15 to 17 as microseconds and 18 or more as nanoseconds, so 1700000000000 is read as milliseconds: 22:13:20 UTC on 14 November 2023.

Results cover the years 0001 to 9999, the range of a four-digit ISO 8601 year. Negative timestamps are instants before 1970; −86400 is midnight UTC on 31 December 1969.

What time is it in UTC, EST, PST and GMT?

Local time is UTC plus the zone's offset for that date. In January, 12:00 UTC is 12:00 in London (GMT), 07:00 in New York (EST, UTC−05:00) and 04:00 in Los Angeles (PST, UTC−08:00). In summer those three clocks read an hour later, so 12:00 UTC is 08:00 in New York.

The same two moments, noon UTC on 15 January and 1 July 2026, in each zone:

Time zoneJanuary local clockJuly local clock
UTC12:00:0012:00:00
America/New_York07:00:0008:00:00
America/Chicago06:00:0007:00:00
America/Los_Angeles04:00:0005:00:00
Europe/London12:00:0013:00:00
Asia/Shanghai20:00:0020:00:00
Asia/Seoul21:00:0021:00:00
Asia/Karachi17:00:0017:00:00
Asia/Kolkata17:30:0017:30:00

China, South Korea, Pakistan and India don't change their clocks, so their offsets stay at UTC+08:00, UTC+09:00, UTC+05:00 and UTC+05:30 all year. Chicago keeps US Central time, which Houston also uses.

GMT is a fixed UTC+00:00 clock, but London uses it only in winter. From late March to late October the UK is on British Summer Time, UTC+01:00 (GOV.UK's clock-change dates), so London is then an hour ahead of GMT.

How to convert a Unix timestamp to a date

A Unix timestamp counts the seconds since 00:00:00 UTC on 1 January 1970, with every day exactly 86,400 seconds long. Divide by 86,400: the whole number is the day count since 1970 and the remainder is the time of day in UTC. 1700000000 is 19,675 days and 80,000 seconds, which is 22:13:20 UTC on 14 November 2023.

InputInput unitUTC ISO result
0s1970-01-01T00:00:00Z
-86400s1969-12-31T00:00:00Z
1700000000auto2023-11-14T22:13:20Z
1700000000000auto2023-11-14T22:13:20Z
2147483647auto2038-01-19T03:14:07Z
2147483648auto2038-01-19T03:14:08Z

Milliseconds, microseconds and nanoseconds count the same instant in smaller steps; divide by 1,000, 1,000,000 or 1,000,000,000 to get seconds. Without a stated unit, up to 11 digits are read as seconds, 12 to 14 as milliseconds, 15 to 17 as microseconds and 18 or more as nanoseconds.

That digit rule misreads millisecond counts from before 3 March 1973, which have 11 digits or fewer, and leading zeros don't add digits. Set the unit explicitly for values that close to the epoch.

Negative timestamps are before 1970, and fractions stay part of the instant: −0.5 is 1969-12-31T23:59:59.5Z.

The last two rows straddle the signed 32-bit limit: software that stores Unix time in 32 bits overflows after 03:14:07 UTC on 19 January 2038, but the count itself carries on. Dates from year 0001 to 9999 convert.

Converting ISO 8601 times and local dates

An ISO 8601 time ending in Z is UTC, and an explicit offset names the same instant another way: 2026-01-15T18:30:00+05:30 is 2026-01-15T13:00:00Z. Without Z or an offset, the time is read in the chosen zone, so keep the offset when you share a timestamp.

A local date and time becomes a timestamp through its zone's offset on that date. In autumn one hour happens twice: 01:30 on 1 November 2026 in New York is 1793511000 the first time and 1793514600 the second.

In spring a skipped time moves forward by the gap, so 01:30 on 29 March 2026 in London becomes 02:30 BST, timestamp 1774747800. To compare one local time with several cities at once, use the time zone converter.

EST, EDT, CST, PST and PDT are fixed offsets

An abbreviation names one fixed offset: EST is UTC−05:00 all year and EDT is UTC−04:00. New York switches between them, so in July "Eastern time" is EDT, and a literal EST clock reads an hour earlier than clocks in New York. Central (Chicago) and Pacific (Los Angeles) time switch the same way.

At noon UTC on the same two dates, the fixed clocks don't move:

Fixed clock conventionTime zone selectionJanuary clockJuly clock
US ESTUTC−05:0007:00:0007:00:00
US EDTUTC−04:0008:00:0008:00:00
US CSTUTC−06:0006:00:0006:00:00
US PSTUTC−08:0004:00:0004:00:00
US PDTUTC−07:0005:00:0005:00:00
China Standard TimeUTC+08:0020:00:0020:00:00

Abbreviations also need a country. CST also means China Standard Time, UTC+08:00, in Shanghai; in the Philippines, PST is Philippine Standard Time, the UTC+08:00 clock in Manila. IST can mean India, Ireland or Israel.

NIST's official US time display shows the US zones, and its daylight-saving guidance gives the dates the clocks change.

Clock accuracy and leap seconds

The current time comes from your device's clock, shown to the second. It is not synchronized with an atomic clock, so a device that runs a few seconds fast shows a time a few seconds fast.

Unix time has no leap seconds: POSIX's time definition counts every day as 86,400 seconds. Time-zone offsets come from the IANA time zone database, which changes when governments change their rules; a fixed offset such as UTC−05:00 never follows those changes.

Worked examples

The epoch

Direction
Timestamp to date
Timestamp
0
Timestamp unit
Seconds
Time zone
UTC
ISO 8601 (UTC)
1970-01-01T00:00:00Z
Day of the week (UTC)
Thursday

Checked against: POSIX definition

Largest signed 32-bit value (year 2038)

Direction
Timestamp to date
Timestamp
2147483647
Timestamp unit
Detect from length
Time zone
UTC
ISO 8601 (UTC)
2038-01-19T03:14:07Z
Read as
seconds

Checked against: Independent calculation

Milliseconds shown in India

Direction
Timestamp to date
Timestamp
1700000000000
Timestamp unit
Detect from length
Time zone
India (Kolkata)
ISO 8601 (UTC)
2023-11-14T22:13:20Z
Local time in the chosen zone
2023-11-15 03:43:20 (UTC+05:30)
Unix seconds
1700000000
Read as
milliseconds

Checked against: Independent calculation

Negative timestamp

Direction
Timestamp to date
Timestamp
-86400
Timestamp unit
Seconds
Time zone
UTC
ISO 8601 (UTC)
1969-12-31T00:00:00Z
Day of the week (UTC)
Wednesday

Checked against: Independent calculation

Questions

What is the year 2038 problem?

Software that stores Unix time in a signed 32-bit integer can count only to 2,147,483,647 seconds, reached at 03:14:07 UTC on 19 January 2038. One second later the value wraps to −2,147,483,648, which reads as 20:45:52 UTC on 13 December 1901. A signed 64-bit count, the usual size on current 64-bit systems, lasts about 292 billion years.

How can I tell whether a timestamp is in seconds or milliseconds?

Count the digits. Present-day times have 10 digits in seconds, 13 in milliseconds, 16 in microseconds and 19 in nanoseconds; the seconds count reached 1,000,000,000 on 9 September 2001 and stays at 10 digits until 20 November 2286. JavaScript's Date.now() and Java's System.currentTimeMillis() return milliseconds, while the shell command date +%s and Python's time.time() return seconds.

Does Unix time count leap seconds?

No. POSIX defines every day as 86,400 seconds, so the 27 leap seconds added to UTC between 1972 and 2016 have no timestamps of their own, and 23:59:60 cannot be written as Unix time. Systems either repeat a second when one occurs or spread it out; Google, for example, smears a leap second over the 24 hours from noon to noon UTC.

Is a Unix timestamp the same in every time zone?

Yes. A timestamp names one instant, and the zone only changes how that instant is written. Timestamp 0 is 00:00 UTC on 1 January 1970, which was 05:30 the same day in India, 19:00 on 31 December 1969 in New York, and 01:00 in London, where British Standard Time kept clocks on UTC+01:00 all year from 1968 to 1971.

How do I get the current Unix timestamp?

Type now in the timestamp box, or ask the system clock: date +%s in a Linux or macOS shell, Math.floor(Date.now() / 1000) in JavaScript, int(time.time()) in Python, and SELECT UNIX_TIMESTAMP() in MySQL. The count grows by 86,400 a day and passes 1,800,000,000 at 08:00 UTC on 15 January 2027.

About this calculator

t=86400×N(date)+3600h+60m+s,N=days since 1970-01-01t = 86400 \times N(\text{date}) + 3600h + 60m + s,\qquad N = \text{days since 1970-01-01}

Sources

  1. POSIX.1-2017, §4.16 Seconds Since the Epoch
  2. ISO 8601-1:2019 — Date and time representations
  3. IANA Time Zone Database

Checked against references

This calculator includes 8 worked examples with independently sourced answers. They run in the test suite, and you can run them here too.

Put this calculator on your site

Paste this where you want the calculator to appear. It is free to use, it stays in step with corrections made here, and the credit line below it links back so your readers can find the full version.

Height
Preview the embed

Keep the credit line. It is the only condition, and it is what keeps these calculators free.