Date & time · Unix epoch
Unix timestamp converter.
Turn epoch time into a readable date, or a date into a Unix timestamp. Seconds, milliseconds, microseconds and nanoseconds are detected automatically. Nothing leaves your browser.
Convert
Result
Enter a timestamp or a date to convert.
Epoch time, in short
Unix time (also called epoch time or POSIX time) is the number of seconds since 1970-01-01 00:00:00 UTC, with every day counted as exactly 86,400 seconds. Many systems store it in milliseconds instead: JavaScript Date and Java System.currentTimeMillis() both do. This converter reads the unit from the number of digits, or you can set it yourself.
Examples
These values are computed with the same code that powers the converter.
| Unix seconds | UTC date and time |
|---|---|
0 | 1970-01-01T00:00:00Z |
1 | 1970-01-01T00:00:01Z |
-1 | 1969-12-31T23:59:59Z |
86400 | 1970-01-02T00:00:00Z |
1000000000 | 2001-09-09T01:46:40Z |
1234567890 | 2009-02-13T23:31:30Z |
1700000000 | 2023-11-14T22:13:20Z |
1709654400 | 2024-03-05T16:00:00Z |
2147483647 | 2038-01-19T03:14:07Z |
2147483648 | 2038-01-19T03:14:08Z |
4294967295 | 2106-02-07T06:28:15Z |
Current epoch time in code
Each row gives the current time, a timestamp turned into a UTC date, and a UTC date turned into a timestamp, using 1709654400 (2024-03-05T16:00:00Z). Python rows assume import time and from datetime import datetime, timezone; Java rows assume java.time.Instant.
| Language | Now | Timestamp to date | Date to timestamp |
|---|---|---|---|
| JavaScript | Math.floor(Date.now() / 1000) | new Date(1709654400 * 1000).toISOString() | Math.floor(Date.parse('2024-03-05T16:00:00Z') / 1000) |
| Python | int(time.time()) | datetime.fromtimestamp(1709654400, tz=timezone.utc) | int(datetime(2024, 3, 5, 16, tzinfo=timezone.utc).timestamp()) |
| Go | time.Now().Unix() | time.Unix(1709654400, 0).UTC() | time.Date(2024, 3, 5, 16, 0, 0, 0, time.UTC).Unix() |
| Java | Instant.now().getEpochSecond() | Instant.ofEpochSecond(1709654400L) | Instant.parse("2024-03-05T16:00:00Z").getEpochSecond() |
| PostgreSQL | SELECT EXTRACT(EPOCH FROM now())::bigint; | SELECT to_timestamp(1709654400); | SELECT EXTRACT(EPOCH FROM timestamptz '2024-03-05 16:00:00+00'); |
| SQLite | SELECT unixepoch(); | SELECT datetime(1709654400, 'unixepoch'); | SELECT unixepoch('2024-03-05 16:00:00'); |
The year 2038 limit and leap seconds
A signed 32-bit seconds counter overflows after 2147483647, which is 2038-01-19T03:14:07Z; the next second wraps to a date in 1901. See the 2038 problem checker. Unix time also ignores leap seconds, so it is not a strict count of elapsed SI seconds.
Related converters
Epoch to date (paste many values), date to epoch, Unix time in milliseconds, Excel date to Unix and days since epoch.
FAQ
What is Unix epoch time?
Unix time counts seconds since 00:00:00 UTC on 1 January 1970, the Unix epoch. POSIX defines it so that every day is exactly 86,400 seconds, which is why 1970-01-02T00:00:00Z is 86400.
How do I convert a Unix timestamp to a date?
Type the number into the Unix timestamp box. The converter reads the unit from its length, then shows the date in the zone you pick, in UTC, as ISO 8601 and as an RFC 2822 date. To go the other way, switch to Date to Unix timestamp.
How can I tell seconds from milliseconds?
Current times have 10 digits in seconds, 13 in milliseconds, 16 in microseconds and 19 in nanoseconds. The auto-detect rule here is: below 100 billion is seconds, below 100 trillion is milliseconds, below 100 quadrillion is microseconds, anything larger is nanoseconds. Choose a unit yourself if a value sits near a boundary.
Does Unix time include leap seconds?
No. POSIX counts each day as exactly 86,400 seconds, so a leap second is not a separate value: the timestamp repeats or is smeared by the system clock, and 2017-01-01T00:00:00Z is 1483228800 even though UTC itself had a leap second added at the end of 2016. IERS Bulletin C 72 (July 2026) announced that no leap second will be introduced at the end of December 2026.
Can a Unix timestamp be negative?
Yes. A negative value is a moment before 1970-01-01, for example -1 is 1969-12-31T23:59:59Z. POSIX leaves the formula undefined before 1970, but most languages extend the same arithmetic backwards and so does this tool.
What is the year 2038 problem?
A signed 32-bit integer tops out at 2,147,483,647 seconds, which is 2038-01-19T03:14:07Z. One second later it wraps to -2,147,483,648, which reads as 1901-12-13T20:45:52Z. The Linux kernel documentation notes that the 32-bit tv_sec member overflows in 2038. Systems that store time in 64 bits are not affected. Check a value for 32-bit overflow.
Which time zone is a Unix timestamp in?
None. It identifies one instant, counted from the epoch in UTC. A time zone only matters when you turn the number into a calendar date and clock time, or the other way round.
What is the largest date this converter accepts?
JavaScript time values run from -8,640,000,000,000,000 to 8,640,000,000,000,000 milliseconds around the epoch, about 275,000 years either side of 1970. Values outside that range are rejected rather than guessed.
Is my data sent anywhere?
No. The conversion runs in your browser and nothing you type is uploaded or stored.
Sources (each opened 2026-10): POSIX.1-2017 Base Definitions, 4.16 Seconds Since the Epoch; RFC 3339, Date and Time on the Internet: Timestamps; RFC 5322, Internet Message Format (obsoletes RFC 2822); ECMAScript Language Specification, Time Values and Time Range; IERS Bulletin C 72 (leap second announcement, July 2026); Linux kernel documentation, Timekeeping; Python documentation, datetime; Python documentation, time; Go documentation, package time; Java SE 21 API, java.time.Instant; Java SE 21 API, java.lang.System; PostgreSQL documentation, Date/Time Functions; SQLite documentation, Date And Time Functions.