What a Unix timestamp actually is
A Unix timestamp is a count of seconds since 00:00:00 UTC on 1 January 1970, ignoring leap seconds. It has no time zone: 1727438400 is the same instant in Dubai, London and São Paulo, and only turns into a wall-clock time once you choose a zone. That is precisely why it is the format systems exchange — and precisely why bugs appear when one side assumes the timestamp is "local".
Seconds or milliseconds?
The most common conversion bug is a factor of a thousand. Unix, most databases and JWT claims use seconds; JavaScript's Date.now(), Java's System.currentTimeMillis() and most JSON APIs use milliseconds; some tracing systems use microseconds or nanoseconds. This tool detects the unit from the number's magnitude — a 10-digit number is seconds, 13 is milliseconds — and says which it assumed, so a value that decodes to the year 56,000 is caught immediately.
ISO 8601 and RFC 3339
2026-09-27T12:00:00Z is the interchange form: unambiguous, sortable as a string, and parsed by every language. The trailing Z means UTC; +04:00 is an offset. A value without either is ambiguous, and JavaScript treats the date-only form 2026-09-27 as UTC but the date-time form 2026-09-27T12:00 as local — a distinction that has produced a great many off-by-a-day bugs.
RFC 2822 / HTTP dates
Sat, 27 Sep 2026 12:00:00 GMT is the form in email headers, HTTP Date, Last-Modified and Expires headers, and cookies. HTTP requires GMT specifically. It is shown here so you can paste it straight into a cache header or compare it with what a server sent.
Weeks, quarters and day-of-year
ISO 8601 week numbers start on Monday and week 1 is the week containing the first Thursday, which means 1 January can belong to week 52 or 53 of the previous year. The result shows the ISO week and week-year together, because reporting code that uses the calendar year with the ISO week produces wrong figures every December and January.
The 2038 problem, and other limits
A signed 32-bit integer runs out at 2,147,483,647 seconds — 03:14:07 UTC on 19 January 2038. Systems that still store timestamps in 32 bits (embedded devices, old file systems, some database columns) wrap to 1901 at that moment. The converter flags any value beyond the 32-bit range. JavaScript's own Date covers ±8.64 × 1015 milliseconds, about ±273,000 years, so inputs beyond that are refused rather than silently corrupted.
Negative timestamps are valid and mean before 1970: -86400 is 31 December 1969. Not every system accepts them — MySQL's TIMESTAMP column does not — so if you store dates before 1970 in a Unix column, check the column type first.
Time zones are not offsets
An offset like +04:00 is a fixed number; a zone like Asia/Dubai is a set of rules that say what the offset is at any given moment, including daylight-saving changes and historical reforms. Dubai's rules are simple (permanently +04:00); Europe/London switches between +00:00 and +01:00 twice a year, and the switch dates themselves have changed over the decades. Store instants as UTC, store the zone name alongside when you need to reproduce a wall-clock time, and never store an offset thinking it is a zone. The zone table above uses the browser's own tz database through Intl.DateTimeFormat, which is how it can show the correct offset for a date years in the past.
Getting the current timestamp in common languages
| Language | Seconds | Milliseconds |
| JavaScript | Math.floor(Date.now() / 1000) | Date.now() |
| Python | int(time.time()) | int(time.time() * 1000) |
| Go | time.Now().Unix() | time.Now().UnixMilli() |
| Java / Kotlin | Instant.now().getEpochSecond() | System.currentTimeMillis() |
| C# | DateTimeOffset.UtcNow.ToUnixTimeSeconds() | DateTimeOffset.UtcNow.ToUnixTimeMilliseconds() |
| PHP | time() | (int) (microtime(true) * 1000) |
| Shell | date +%s | date +%s%3N (GNU) |
| PostgreSQL | extract(epoch from now())::bigint | (extract(epoch from now()) * 1000)::bigint |
| MySQL | UNIX_TIMESTAMP() | ROUND(UNIX_TIMESTAMP(NOW(3)) * 1000) |