About the Unix Timestamp Converter
A Unix timestamp counts the seconds since 00:00:00 UTC on January 1, 1970. It is how databases, logs and APIs store time, but it is unreadable to humans. This Unix timestamp converter turns epoch seconds into a local date and time, converts a date back into a timestamp, and shows the current Unix time ticking live.
How it works
Values with 13 or more digits are read as milliseconds, shorter ones as seconds (multiplied by 1,000, since JavaScript dates use milliseconds). The result is shown in your local time, in UTC, in ISO 8601, and relative to now.
To turn a date into a timestamp, it reads the date and time you pick as local time, gets the milliseconds since the epoch, divides by 1,000 and rounds down. Because the epoch is defined in UTC, the same instant has the same timestamp everywhere, even though it displays as different local times.
How to use
- 1
Read or note the Current Unix timestamp at the top.
- 2
To decode a timestamp, type it in Timestamp to Date (seconds or milliseconds) and read the local, UTC, ISO and relative values below it.
- 3
To create a timestamp, pick a date and time in Date to Timestamp and read the seconds, milliseconds and ISO values below it.
- 4
Click the copy icon next to a result to copy it.
Worked examples
Decode a log timestamp
A log line shows 1700000000.
Start of 2027
A developer needs the timestamp for midnight UTC on January 1, 2027, on a computer set to UTC.
A future milestone
Checking when timestamp 2000000000 occurs.
Frequently asked questions
What is a Unix timestamp used for?+
It represents a point in time as a single number of seconds since January 1, 1970 UTC. Databases, APIs, log files and tokens use it because it is compact and independent of time zones and date formats.
Is a Unix timestamp in seconds or milliseconds?+
Traditionally seconds. JavaScript and some APIs use milliseconds. This converter detects which: 13 or more digits are read as milliseconds.
Why does the converted date differ from UTC?+
The Local row uses your device's time zone. The UTC and ISO rows show the same moment in UTC.
How do I get the current Unix timestamp?+
It is shown at the top of the tool and updates every second. In code, Math.floor(Date.now() / 1000) in JavaScript or time.time() in Python returns the same value.
What is the Unix epoch?+
The epoch is 00:00:00 UTC on January 1, 1970, the moment Unix time counts from. Its timestamp is 0.