Milliseconds in practice
A 13-digit epoch is almost always milliseconds: Kafka record timestamps, Elasticsearch date fields, MongoDB $date, Java Instant.toEpochMilli() and every browser Date. With the unit locked to milliseconds, the ISO output keeps three fractional digits even when they are zeros. That makes it clear the value is millisecond-precise rather than truncated to the second.
If you are moving a value into a system that uses seconds, copy the "Unix seconds" row. It is the exact quotient, so 1700000000123 ms becomes 1700000000.123. Copy "Unix seconds (integer, floor)" when the target only takes whole seconds.
Examples to try
Common millisecond mistakes
Passing milliseconds to Python datetime.fromtimestamp() raises "year out of range" because it expects seconds. Passing seconds to JavaScript new Date() gives a date in January 1970. Storing milliseconds in a 32-bit integer overflows after 24.8 days of uptime. When you lock the unit here and the result is not a plausible date, a warning shows what the value would be in each other unit.
Questions
- How do I convert milliseconds to seconds?
- Divide by 1000. The converter shows both the exact decimal (1700000000.123) and the floored integer (1700000000), so you can pick the right one for the target system.
- What is the largest millisecond timestamp JavaScript supports?
- 8,640,000,000,000,000 ms, which is +275760-09-13T00:00:00Z. Beyond that, new Date() returns Invalid Date. This tool still converts those values exactly in UTC.
- Why does a millisecond value show .000 in the ISO output?
- The output keeps the precision of the input. A millisecond timestamp is precise to the millisecond, so three fractional digits are shown. Use the precision menu to change this.