Connect via MCP →

Enter Calculation

Formula

Advertisement

Results

Elapsed time
7:10:00
hours : minutes : seconds
In hours 7.166667 h
In minutes 430 min
In seconds 25,800 s

What this calculator does

This tool computes the elapsed time between a start time and an end time, where each time is entered as an hour, minute, and second within a day. It returns the duration in a familiar H:MM:SS format and also expressed as a decimal total in hours, in minutes, and as a whole number of seconds. The math is pure clock arithmetic and works the same everywhere, regardless of region or time zone.

Timeline showing start and end markers with shaded elapsed duration between them
Elapsed time is the shaded span from the start time to the end time.

How to use it

Enter the start time (hour, minute, second) and the end time (hour, minute, second). Use a 24-hour clock so that, for example, 3:40 PM is entered as hour 15. Press calculate. If the end time falls earlier than the start time, the calculator assumes the end time is on the next day and adds 24 hours automatically — perfect for overnight shifts or sleep that crosses midnight.

The formula explained

Each time is converted to total seconds of the day: hour times 3600 plus minute times 60 plus seconds. The difference is endTotal minus startTotal. When that difference is negative, the calculator adds 86400 (the number of seconds in one day) so the result wraps to the next day. From the resulting total seconds, hours are the floor of seconds divided by 3600, minutes are the floor of the remainder divided by 60, and seconds are the remainder modulo 60.

$$\begin{gathered} \Delta t = \left(E - S\right) \bmod 86400 \quad\text{seconds} \\[1.5em] \text{where}\quad \left\{ \begin{aligned} S &= 3600\,\text{Start h} + 60\,\text{Start m} + \text{Start s} \\ E &= 3600\,\text{End h} + 60\,\text{End m} + \text{End s} \end{aligned} \right. \end{gathered}$$
Circular 24-hour dial with arrow sweeping past midnight from evening start to morning end
When the end time is earlier than the start, the duration rolls over past midnight.

Worked example

Start = 08:30:00 gives 30,600 seconds. End = 15:40:00 gives 56,400 seconds. The difference is 25,800 seconds, which is 7 hours, 10 minutes, 0 seconds — shown as 7:10:00. As totals that is 7.166667 hours, 430 minutes, or 25,800 seconds.

$$\Delta t = (56{,}400 - 30{,}600) \bmod 86400 = 25{,}800 \text{ s} = 7{:}10{:}00$$

FAQ

What if the end time is before the start time? The end time is treated as the next day, so a full 24 hours (86400 seconds) is added to the difference. For example 22:00 to 06:30 yields 8:30:00.

What if start equals end? The elapsed time is 0:00:00. Only strictly negative differences roll over to the next day.

What can I use it for? Common uses include measuring sleep duration, work or overtime hours, shift length, waiting time, and timers that cross midnight.

Last updated: