Dev Tools Dev Unix Timestamp Converter
100% client-side · No signup · Free forever

Unix Timestamp Converter

Convert between Unix epoch timestamps and human-readable dates.

1
Dev tool
Unix Timestamp Converter
Live
Unix Timestamp
Date / Time
Current timestamp:

A Unix timestamp converter translates between Unix epoch time (seconds or milliseconds since 1970-01-01T00:00:00Z) and human-readable dates. Unix timestamps are the universal time format in computing — you'll find them in API responses (created_at: 1713456789), database updated_at columns, log files, JWT expiration claims, Stripe webhooks, GitHub Actions logs, and almost every server-to-server protocol. Being able to convert quickly in either direction saves you from squinting at numeric timestamps and miscounting.

How the Timestamp Converter Works

The converter auto-detects whether you've entered seconds (10 digits, e.g. 1713456789) or milliseconds (13 digits, e.g. 1713456789000) based on the magnitude — values above 1012 are treated as milliseconds. The corresponding date is computed with the JavaScript Date constructor and displayed in UTC, ISO 8601, your local timezone, and as a relative time (“2 hours ago”). In the reverse direction, you pick a date/time and we emit both the seconds and milliseconds representations along with the full ISO 8601 string.

When to Convert Timestamps

  • API debugging — what does "exp": 1713456789 mean in human terms?
  • Log analysis — correlating events across services that log in epoch time.
  • JWT debugging — checking when a token was issued (iat) and when it expires (exp).
  • Database queries — building WHERE created_at > ? clauses against epoch columns.
  • Cron jobs — verifying that a scheduled job ran at the expected time.
  • Webhook payloads — Stripe, GitHub, Slack all include epoch timestamps in their event payloads.

Timestamp Conversion in Code

// JavaScript
const ts = Math.floor(Date.now() / 1000);      // current epoch in seconds
const date = new Date(ts * 1000);              // epoch (s) => Date
const iso = date.toISOString();                // ISO 8601 string

// Python
import time, datetime
ts = int(time.time())
date = datetime.datetime.fromtimestamp(ts, tz=datetime.timezone.utc)

// Shell
date +%s                              # current epoch
date -d @1713456789                   # epoch => date (GNU)
date -r 1713456789                    # epoch => date (BSD/macOS)

Seconds vs. Milliseconds vs. Microseconds

Unix timestamps come in three common precisions: seconds (10 digits, classic Unix, most databases, JWT exp/iat); milliseconds (13 digits, JavaScript Date.now(), Java System.currentTimeMillis(), most modern APIs); and microseconds/nanoseconds (16-19 digits, used by some observability tools). When integrating with a new API, always check the units — passing milliseconds where seconds are expected gives you a date in the year 56,000+. The Year 2038 problem affects 32-bit signed timestamp storage (overflows at 2,147,483,647 seconds = 2038-01-19); most modern systems use 64-bit timestamps which won't overflow for ~292 billion years.