When to use it
Use this tool to turn a Unix timestamp into a readable date, or a date into a timestamp. Developers see timestamps in logs, databases, APIs, cookies and JSON Web Tokens. Being able to read them quickly helps when debugging, checking when something happened, or setting an expiry time.
How to use it
The top of the tool shows the Current Unix time, updating every second, with a Copy button.
Timestamp to date
- Paste a number into Unix timestamp. Seconds or milliseconds are detected automatically.
- Read the results: Your time, UTC, ISO 8601, Relative (such as 3 days ago), Seconds and Milliseconds.
- Click the copy button next to any line.
Date to timestamp
- Choose a Date and Time.
- Under Time zone, choose My local time or UTC.
- Read the Seconds, Milliseconds and ISO 8601 values.
Worked example
A log line shows 1767225600. Paste it in and the UTC line reads Thu, 01 Jan 2026 00:00:00 GMT, midnight on New Year’s Day 2026. The Your time line shows the same moment in your own time zone, so in New York it would be the evening of 31 December 2025.
Now you need a timestamp for an offer that ends at 09:00 UTC on 1 March 2027. Choose that date and time, select UTC, and the seconds value is 1803891600. Add three zeros for milliseconds: 1803891600000.
Where you will see timestamps
- Logs and databases: created and updated times are often stored as seconds or milliseconds.
- APIs: many return times as numbers in JSON.
- JSON Web Tokens: the exp and iat fields are timestamps in seconds.
- JavaScript: Date.now() returns milliseconds.
Tips
- Store times in UTC. Convert to local time only when showing it to people.
- Check the digit count. A 13-digit value is milliseconds. Dividing by 1,000 gives seconds.
- Compare two events quickly. Subtract one timestamp from another to get the seconds between them, then divide by 86,400 for days.
- Use ISO 8601 for readable data. Text like 2026-01-01T00:00:00.000Z is clear to people and to most software.
Common mistakes
- Mixing up seconds and milliseconds. A seconds value read as milliseconds lands in January 1970.
- Forgetting the time zone when converting a date. 09:00 local time and 09:00 UTC give different timestamps unless you live in UTC.
- Using the relative time for records. “3 days ago” changes every day. Store the exact value.