Unix timestamps explained: seconds, milliseconds, and time zones
Learn what Unix time is, how to tell seconds from milliseconds, and how to convert timestamps when debugging APIs and JWTs.
The epoch
A Unix timestamp counts seconds (or milliseconds) since 00:00:00 UTC on 1 January 1970. It is a single number that represents an instant, independent of how you format the calendar date later.
Seconds or milliseconds?
Ten-digit values near “now” are usually seconds. Thirteen-digit values are usually milliseconds (as in JavaScript Date.now()). Mixing them up shifts dates by centuries—always check the magnitude.
Local display vs UTC
The instant is absolute; your browser displays it in a time zone. When scheduling across cities, compare with a world clock and confirm whether an API stores UTC.
Try related tools
- Unix timestamp — Convert between Unix seconds, milliseconds, and local time.
- JWT decoder — Inspect JWT header and payload (no signature verification).
- World clock — See the current time in several cities at once.