Current Unix Timestamp

See the current Unix timestamp (epoch time) in seconds and milliseconds, updating live. Convert it to a human-readable date or paste any timestamp to decode it instantly.

What Is the Current Unix Timestamp?

The Unix timestamp is the number of seconds elapsed since January 1, 1970 00:00:00 UTC (the Unix epoch). The converter shows the current value live and lets you convert any timestamp to a readable date.

  • Live display: Current timestamp in seconds and milliseconds, updating every second
  • Paste to decode: Enter any timestamp to see the corresponding UTC and local date/time
  • Epoch to date: Convert in both directions โ€” timestamp to date or date to timestamp
  • Milliseconds support: Works with both 10-digit (seconds) and 13-digit (milliseconds) timestamps

Getting the Current Timestamp in Code

  • JavaScript: Math.floor(Date.now() / 1000) (seconds) or Date.now() (milliseconds)
  • Python: import time; int(time.time()) (seconds) or int(time.time() * 1000) (ms)
  • Go: time.Now().Unix() (seconds) or time.Now().UnixMilli() (ms)
  • Bash/shell: date +%s (seconds) or date +%s%3N (milliseconds on Linux)
  • SQL (PostgreSQL): EXTRACT(EPOCH FROM NOW())::BIGINT
  • SQL (MySQL): UNIX_TIMESTAMP()

Common Timestamp Reference Points

  • Unix epoch: 0 = January 1, 1970 00:00:00 UTC
  • Y2K38 problem: 2,147,483,647 = January 19, 2038 โ€” the maximum value for a 32-bit signed integer timestamp; systems using int32 will overflow on this date
  • Millisecond timestamps: 13-digit values (e.g., 1700000000000) โ€” used by JavaScript's Date.now(), Java's System.currentTimeMillis(), and many modern APIs
  • Negative timestamps: Dates before January 1, 1970 โ€” supported by most modern implementations but not by all legacy systems

Frequently Asked Questions

Why do Unix timestamps use 1970 as the starting point?

The Unix epoch of January 1, 1970 was chosen by the original Unix developers at Bell Labs in the early 1970s. They needed a convenient recent date that fit within the integer range of contemporary hardware. There's no deep significance โ€” it was simply a practical choice made when Unix was being designed. The exact moment (midnight UTC on Jan 1, 1970) became a global standard as Unix spread.

What's the difference between a 10-digit and 13-digit timestamp?

A 10-digit timestamp counts seconds since the epoch (e.g., 1700000000). A 13-digit timestamp counts milliseconds (e.g., 1700000000000 = same moment ร— 1000). Most Unix tools, databases, and server logs use second-precision. JavaScript's Date.now() and many modern APIs use millisecond-precision. When a timestamp looks too large or decodes to the wrong date, check whether it's in seconds or milliseconds โ€” dividing by 1000 converts ms to seconds.

How do I convert a Unix timestamp to a readable date in JavaScript?

Use new Date(timestamp * 1000).toISOString() for a second-precision timestamp (multiply by 1000 to convert to ms), or new Date(timestamp).toISOString() for a millisecond timestamp. For local time: new Date(timestamp * 1000).toLocaleString(). The Intl.DateTimeFormat API gives more control over locale and timezone formatting.