TimestampUnix

epoch ↔ date

Epoch Converter

Convert Unix epoch time to human-readable dates and back. Both directions, all four precisions, every standard format — computed locally in your browser withBigInt so nothing loses precision.

Current Unix time

Live — loading…

Seconds

—

Milliseconds

—

Microseconds

—

Nanoseconds

—

Interpret input as

Accepts Unix timestamps (s / ms / µs / ns), ISO 8601, RFC 2822 and common date strings.

Epoch to date

The converter above turns any epoch value into UTC, local time, your chosen IANA timezone, ISO 8601, RFC 3339, RFC 2822 and relative time. The unit is auto-detected: 10 digits is seconds, 13 is milliseconds, 16 is microseconds, 19 is nanoseconds. Negative values are pre-1970 instants.

Date to epoch

Use the form below when you start from a wall-clock reading. The timezone matters: the same date and time denotes different epoch values in different zones.

A timezone is required — the same local date and time is a different instant in each zone.

  • Unix timestamp (seconds)

    —

  • Milliseconds

    —

  • Microseconds

    —

  • Nanoseconds

    —

  • ISO 8601 (UTC)

    —

Epoch conversion quick reference

TaskJavaScriptPython
Now (seconds)Math.floor(Date.now() / 1000)int(time.time())
Epoch → datenew Date(epoch * 1000)datetime.fromtimestamp(epoch, timezone.utc)
Date → epochMath.floor(date.getTime() / 1000)int(dt.timestamp())
Epoch → ISOnew Date(epoch * 1000).toISOString()datetime.fromtimestamp(epoch, timezone.utc).isoformat()

Why 1970?

The epoch was chosen in 1971 as a convenient round date near the birth of Unix itself: January 1, 1970 00:00:00 UTC. It is an arbitrary anchor — not astronomical or historical — which is exactly why every system can agree on it. What matters is that the count of elapsed seconds is identical everywhere.

Frequently asked questions

What is epoch time?
Epoch time (Unix time, POSIX time) counts the seconds elapsed since the Unix epoch — 1970-01-01 00:00:00 UTC. It is the most common time representation in computing because a single integer describes an unambiguous instant, independent of calendars and timezones.
Is "epoch converter" different from a "Unix timestamp converter"?
No. Epoch time and Unix timestamps are the same thing under two names. This page provides the full bidirectional conversion: epoch → date and date → epoch, at second, millisecond, microsecond and nanosecond precision.
What is epoch time in milliseconds?
Seconds × 1,000. JavaScript (Date.now()), Java (System.currentTimeMillis()) and SQLite store epoch time in milliseconds — a 13-digit number in the current era. Microseconds are × 1,000,000 (16 digits) and nanoseconds × 1,000,000,000 (19 digits).
Can epoch timestamps be negative?
Yes — negative values count backwards from the epoch. -1 is 1969-12-31 23:59:59 UTC. This converter handles negative epochs for dates back to 1600 and beyond.
Which timezone is epoch time in?
Epoch time is defined relative to UTC and carries no timezone. Timezones only affect the human-readable rendering of the instant — use the timezone selector above to view any epoch value in any IANA zone.

Related tools