Unix Timestamp to Date Converter
A Unix timestamp is a single integer representing the number of seconds elapsed since January 1, 1970, 00:00:00 UTC — a reference point known as the Unix Epoch. This counting system was introduced by early Unix developers and has since become the universal standard for representing time in computing. Every major programming language, database engine, and operating system either natively uses or fully supports Unix timestamps.
Converting a Unix timestamp to a human-readable date is one of the most routine tasks in software development. You'll need it when debugging API responses that return timestamps in their JSON payloads, when reading values from database columns typed as INTEGER or BIGINT, when inspecting server logs or cloud monitoring dashboards, or when working with JWT tokens and OAuth flows that embed issued-at and expiry timestamps.
How timestamp auto-detection works
This tool automatically detects the precision of your timestamp based on its length. A 10-digit value (e.g. 1700000000) is interpreted as seconds — the standard Unix format used by Python, PHP, Go, Ruby, and SQL databases. A 13-digit value (e.g. 1700000000000) is interpreted as milliseconds, which is the default in JavaScript and Java. A 16-digit value represents microseconds (used in PostgreSQL and some Linux kernel APIs), and a 19-digit value represents nanoseconds (used in Go's time.Now().UnixNano()).
Convert Unix timestamp to date in code
JavaScript: new Date(timestamp * 1000).toISOString() (if timestamp is in seconds)
Python: datetime.utcfromtimestamp(ts).strftime('%Y-%m-%d %H:%M:%S')
PHP: date('Y-m-d H:i:s', $timestamp)
MySQL: FROM_UNIXTIME(timestamp)
PostgreSQL: TO_TIMESTAMP(timestamp)
All results on this page are calculated entirely in your browser. No data is sent to any server.