What Unix time is
Unix time counts the seconds since 00:00:00 UTC on 1 January 1970, the Unix epoch. It has no time zone: 1790947200 is the same instant in Kyiv, New York and Tokyo, and only the way it is displayed changes. It ignores leap seconds, so every day is exactly 86,400 seconds long.
The trouble is that systems disagree on the unit. Count the digits:
- Seconds · 10 digitsUnix
date +%s, Pythontime.time(), PostgreSQL, JWTexp. - Milliseconds · 13 digitsJavaScript
Date.now(), JavacurrentTimeMillis(). - Microseconds · 16 digitsPython
datetimeprecision, many tracing tools. - Nanoseconds · 19 digitsGo
UnixNano(), Linuxclock_gettime.
A signed 32-bit integer runs out at 2147483647, which is 03:14:07 UTC on 19 January 2038. Systems that still store Unix time in 32 bits will wrap around to December 1901 — the year 2038 problem.
How to use the converter
- Type or paste a timestamp, or press Use Now. The unit is detected from the number of digits; change Unit if it guessed wrong.
- Read the result in UTC, in your own time zone and as a relative time.
- To go the other way, type a date such as
2026-10-02T13:20:00Zor use Pick a Date. A date without a zone is read in the zone you choose under Dates Without a Zone Are In. - Add the time zones you work with — your teammates', your servers'.
- Turn on Batch Mode to convert a whole column from a log or a spreadsheet, then copy it as CSV.
Examples
Read a timestamp from a log
Ten digits: seconds. Shown in UTC, your zone and as "x hours ago".
1790947200
Recognise milliseconds
Thirteen digits came from JavaScript or Java. Detected as milliseconds.
1790947200000
Turn a date into a timestamp
An ISO 8601 date with a zone gives exact seconds and milliseconds.
2026-10-02T13:20:00Z
Explain a date in January 1970
Seconds read as milliseconds land three weeks after the epoch — a classic bug.
1790947200 read as milliseconds
Unix time in your language
# Now, in seconds import time time.time() # 1790947200.482 (float) int(time.time()) # 1790947200 # Timestamp to an aware datetime from datetime import datetime, timezone datetime.fromtimestamp(1790947200, tz=timezone.utc) # datetime(2026, 10, 2, 13, 20, tzinfo=timezone.utc)
// Now — JavaScript counts milliseconds Date.now() // 1790947200482 Math.floor(Date.now() / 1000) // 1790947200 // Seconds to a Date: multiply by 1000 new Date(1790947200 * 1000).toISOString() // '2026-10-02T13:20:00.000Z'
# Now, in seconds date +%s # Timestamp to a date (UTC) date -u -d @1790947200 # Linux (GNU date) date -u -r 1790947200 # macOS (BSD date)
-- Now, in seconds SELECT extract(epoch FROM now())::bigint; -- Timestamp to timestamptz SELECT to_timestamp(1790947200); -- 2026-10-02 13:20:00+00 (shown in the session's time zone)
Frequently asked questions
Why is my date off by a few hours?
Unix time is always UTC. Something displayed it in a different time zone than you expected — usually the server's zone, or the browser's. Compare the UTC row with your own zone above.
Why does my date show January 1970?
A timestamp in seconds was read as milliseconds. JavaScript's new Date(n) expects milliseconds, so new Date(1790947200) lands on 21 January 1970. Multiply by 1000 first.
Does Unix time count leap seconds?
No. Every Unix day is exactly 86,400 seconds. When a leap second happens, Unix time repeats or smears a second instead of counting it.
Can Unix time be negative?
Yes. Negative values are moments before 1970: -86400 is 31 December 1969.
What happens in 2038?
A signed 32-bit counter reaches its maximum, 2147483647, at 03:14:07 UTC on 19 January 2038, and then wraps to a negative number. 64-bit timestamps, used by modern systems, last for billions of years.