UTILS.
Private by default
ms

Milliseconds Converter

Convert milliseconds to a days, hours, minutes, seconds breakdown and back.

Your files stay on this device

Files are processed in your browser, never uploaded. The site downloads code and assets to run the tools. No accounts or trackers.

Use Download to save this tool as one HTML file for offline use.

Privacy →

About this tool

Break a millisecond value into days, hours, minutes, seconds and milliseconds, or build a total from a duration, all in your browser.

The first box reads its value with parseInt, so anything after a decimal point is dropped. Larger units are taken first: 90061500 becomes 1 day, 1 hour, 1 minute, 1 second and 500 milliseconds. A negative value is split by its absolute size and shown with a minus sign on each part that is not zero.

The second box works backwards. Fill any of the five fields and it shows the total in milliseconds and in seconds. Empty fields count as zero, decimals and negatives are accepted, and a non-numeric field shows an error. Only fixed-length units are used, so there are no month or year parts.

Frequently asked questions

Can it handle very large values?
Yes for everyday values. The input is read as a JavaScript number, so whole numbers above 9,007,199,254,740,991 lose precision.
What does the second box do?
It works in reverse, turning a days/hours/minutes/seconds/ms duration into a single total in milliseconds.
What happens to a decimal like 1500.9?
The first box cuts off the fraction and uses 1500. The second box accepts decimals, so use it to add up fractional seconds or minutes.
Why are there no months or years?
Only fixed-length units are used, from days of 86,400,000 ms down to milliseconds.

More tools