ThisCalculator

Everyday

Subtract Two Times to Get Minutes in Excel

Updated · Standard formula, shown below

Subtract Two Times to Get Minutes in Excel

To subtract two times and get the elapsed minutes in Excel, subtract the earlier time from the later time and multiply the result by 1,440: =(B2-A2)*1440. Enter the start time in A2 and the end time in B2; the formula returns the difference as a number of minutes, including fractional minutes when the times are not exactly on a minute.

Why Multiply by 1,440?

Excel stores times as fractions of a day. Midnight is represented by 0, noon by 0.5, and one full day by 1. Since a day has 24 hours and 60 minutes per hour, it contains 1,440 minutes. Subtracting two time values therefore produces a fraction of a day, not a number of minutes. Multiplying by 1,440 converts that fraction to minutes.

For example, if A2 contains 9:15 AM and B2 contains 10:00 AM, the subtraction gives 0.03125 days. Multiplying by 1,440 gives 45 minutes. The basic formula is:

  • =(end_time-start_time)*1440 for elapsed minutes.
  • =(B2-A2)*1440 when the start and finish times are in cells A2 and B2.

Enter the Formula and Format the Result

  1. Enter the starting time and ending time in separate cells, such as A2 and B2.
  2. In another cell, type =(B2-A2)*1440 and press Enter.
  3. Format the formula cell as a number if Excel displays a clock time or date instead of a minute count. Select the cell, open the number-format options, and choose Number or General.
  4. Choose the desired decimal places. For whole minutes, set zero decimal places or use =ROUND((B2-A2)*1440,0).

The formula returns a numeric value, so you can add, average, or compare the results. If the input cells contain text that only looks like a time, Excel may not subtract them correctly. Enter valid time values or convert the text to times first.

Examples: Whole and Fractional Minutes

Suppose a task starts at 1:20 PM and ends at 2:05 PM. The elapsed time is 45 minutes, so the formula returns 45. For a shorter interval, a start at 8:10 and finish at 8:10:30 produces 0.5 minutes. By default, that fraction remains visible only if the result cell displays decimal places.

To return the number of completed whole minutes rather than a rounded value, use =INT((B2-A2)*1440) for a nonnegative duration. For example, 12.8 minutes becomes 12. Rounding to the nearest minute is different: =ROUND((B2-A2)*1440,0) would make 12.8 become 13. Pick the behavior that matches whether you need an exact duration, completed minutes, or a rounded display.

Times That Cross Midnight

A simple subtraction gives a negative result if the end time is after midnight and the start and end cells contain only times. For example, 11:30 PM to 12:15 AM appears to run backward because Excel treats 12:15 AM as the beginning of the same day. If you know the interval is less than 24 hours, use:

=MOD(B2-A2,1)*1440

The MOD function wraps a negative time difference into the next day. For 11:30 PM to 12:15 AM, this returns 45 minutes. However, it also treats a later finish time as an interval that wraps if the values imply that result. Use it only when that overnight interpretation is appropriate.

If durations can exceed 24 hours or you need to distinguish dates, enter full date-and-time values in both cells—for example, a start date with 11:30 PM and the following date with 1:00 AM. Then use =(B2-A2)*1440. Including the dates removes ambiguity and supports intervals longer than one day.

Display a Duration Instead of a Minute Count

Multiplying by 1,440 is useful when you need a numeric total in minutes. If you would rather show an elapsed time such as 0:45, subtract the times without multiplying: =B2-A2. Format the result cell with the custom format [h]:mm. The square brackets allow the hour count to continue past 24, unlike a normal clock-time display that can roll over at midnight.

These outputs serve different purposes. A value of 1,500 from the minutes formula means 1,500 minutes; a duration formatted as [h]:mm displays the same interval as 25:00. Do not multiply by 1,440 and then format the result as a time duration: the multiplied value is in minutes, while Excel’s duration format expects a fraction of a day.

Common Problems and Useful Variations

  • The result looks like a date or clock: Change the result cell’s format to Number or General. The subtraction itself may be correct.
  • The result is negative: Check that the times are in the intended order. If the period crosses midnight, use the MOD formula or include dates.
  • Excel shows ####: This usually means the column is too narrow for the displayed value, or the cell uses a format that cannot display a negative time. Widen the column and check the format.
  • You need a different unit: Multiply the time difference by 24 for hours or by 86,400 for seconds. These conversions use the number of hours or seconds in a day.
  • You have a list of rows: Put the formula in the first result row and fill it down, adjusting the cell references for each pair of times.

A frequent misconception is that Excel stores a time such as 6:00 PM as the number 18. It stores the time as a fraction of a day; 6:00 PM is 0.75. That is why subtracting times alone does not directly return minutes and why the conversion factor is 1,440.

Frequently Asked Questions

What formula subtracts two times and returns minutes?
Use =(end-start)*1440, such as =(B2-A2)*1440. Format the result cell as Number or General.

How do I get whole minutes in Excel?
Use =ROUND((B2-A2)*1440,0) to round to the nearest minute. Use =INT((B2-A2)*1440) to count completed whole minutes for a nonnegative interval.

How do I calculate minutes when the time crosses midnight?
If the interval is under 24 hours and the cells contain times only, use =MOD(B2-A2,1)*1440. For longer or date-specific intervals, enter the dates as well and use the ordinary subtraction formula.

Why does Excel show a decimal after I subtract times?
Excel stores time as part of a day, so direct subtraction returns a fraction of a day. Multiply by 1,440 to convert that fraction to minutes.

How can I show elapsed hours and minutes instead of total minutes?
Use =B2-A2 and format the result as [h]:mm. The brackets preserve total hours beyond 24.

Related

Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.