Skip to content

Epoch ↔ ISO 8601

Unix Timestamp Converter

Convert Unix epoch timestamps in seconds, milliseconds, microseconds, and nanoseconds to ISO 8601 dates in UTC and your local time, and back.

Result

Current time

ISO 8601

UTC

 

Local

 

Unix timestamp

Secondss

 

Millisecondsms

 

Microsecondsµs

 

Nanosecondsns

 

“Now” reads the browser clock at millisecond precision, so its µs and ns values end in zeros.

Convert. Paste any timestamp.

Unit

Supported range: 0001-01-02T00:00:00Z to 9999-12-30T23:59:59.999999999Z.

Unix time, explained.

What is a Unix timestamp?

A Unix timestamp, also called epoch time or POSIX time, counts the seconds since the Unix epoch: 1970-01-01T00:00:00Z, ignoring leap seconds. Values before 1970 are negative.

A timestamp names the same instant everywhere. Time zones matter only when you format it as a calendar date, which is why the converter shows both UTC and your local time.

What is ISO 8601?

ISO 8601 is the international standard for writing dates and times, such as 2026-11-12T19:04:59.737Z. The Z suffix means UTC; an offset like +07:00 means local time that far ahead of UTC. RFC 3339, used by most APIs and JSON, is a strict profile of ISO 8601.

A date and time without Z or an offset doesn’t identify a single instant, so the converter asks you to add one or use Local mode.

What is the year 2038 problem?

Systems that store Unix seconds in a signed 32-bit integer overflow after 2147483647, which is 2038-01-19T03:14:07Z. The next second wraps to a negative value and reads as 1901. 64-bit timestamps avoid this.

Is my data sent anywhere?

No. Every conversion runs locally in your browser with integer BigInt arithmetic, so nanosecond values round-trip exactly. There’s no backend and no analytics.

Seconds or milliseconds? Count the digits.

For dates between 2001 and 2286, each unit has a fixed length.

Unix timestamp units by digit count, with examples and where each is common
Unit Digits Example Common in
Seconds (s) 10 1794510299 Unix date, PHP, Go Unix(), JWT exp and iat
Milliseconds (ms) 13 1794510299737 JavaScript Date.now(), Java, Kotlin, Dart, Firebase Remote Config
Microseconds (µs) 16 1794510299737000 Databases, logging and tracing systems
Nanoseconds (ns) 19 1794510299737000000 Go UnixNano(), Python time.time_ns(), OpenTelemetry

The converter never guesses the unit. If the digit count doesn’t match the unit you picked, it shows a hint with a one-click switch.

The current timestamp, in code.

Code to get the current Unix timestamp in seconds and milliseconds, by language
Language Seconds Milliseconds
JavaScript Math.floor(Date.now() / 1000) Date.now()
Python int(time.time()) time.time_ns() // 1_000_000
Swift Int(Date().timeIntervalSince1970) Int(Date().timeIntervalSince1970 * 1000)
Kotlin Instant.now().epochSecond System.currentTimeMillis()
Java Instant.now().getEpochSecond() System.currentTimeMillis()
Dart DateTime.now().millisecondsSinceEpoch ~/ 1000 DateTime.now().millisecondsSinceEpoch
Go time.Now().Unix() time.Now().UnixMilli()
C# DateTimeOffset.UtcNow.ToUnixTimeSeconds() DateTimeOffset.UtcNow.ToUnixTimeMilliseconds()
PHP time() (int) floor(microtime(true) * 1000)
PostgreSQL floor(extract(epoch from now()))::bigint floor(extract(epoch from now()) * 1000)::bigint
Shell date +%s date +%s%3N (GNU)