EpochLab

Milliseconds Converter

Convert milliseconds to a date, and back

The 13-digit form. It is what `Date.now()` and `System.currentTimeMillis()` return, and what most Java and JavaScript code uses. Convert it either way, with the seconds value shown beside it.

Questions people ask

The things that come up about milliseconds converters, answered plainly.

How do I convert milliseconds to seconds?

Divide by 1000 and round down. Do not round to the nearest, or a timestamp can land one second in the future. The page shows both values, so you can copy the one you need.

Why does JavaScript use milliseconds?

Because its `Date` was based on Java's, and Java chose milliseconds in 1995. So if you pass a JavaScript timestamp to a Unix API without dividing by 1000, you get a date near the year 45,000.

Related tools

Seconds, milliseconds, microseconds and nanoseconds, in both directions.