Here, youll learn how to get the difference between two times in Excel.
A common example of this is for when someone starts and finishes work.
(Note that my version of Excel put the finish time in the 24 hour time format (military time) but that it is still just 5:45 PM.)
Here we have a start and finish time and I want to see how much time has elapsed between them.
All you need to do is to subtract the starting time from the finish time:
Excel will generally handle the rest.
However, if the display of the new time does not look correct, it should be 7:45 in this case, then we need to make sure the formatting is right.
Right-click the Time cell and select the Format Cells option.
From there, a window will open up that looks like this:
Go to the Number tab and then select Custom from the Category section and make sure that you have selected h:mm from the area on the right. Then, hit OK and everything should work as you expect.
You can also return just the Hours, Minutes, or Seconds from this result by using three simple functions, the HOUR(), MINUTE(), and SECOND() function.
NOTE, these functions in the examples below will not return the total minutes or seconds between two times but will simply break that portion of the time out of the original result.
Here are the three functions:
Here are the results of these functions:
You can see how the total Time is 7 hours and 45 minutes and 0 seconds from cell C2, so these elements are simply broken out into their own cell using the Hour, Minute, and Second functions above.
Time is a very confusing element of Excel, but it can be quite powerful once you get to learn it a bit more.
This tutorial should help provide the foundation for more complex calculations and I urge you to browse the Date and Time Tutorial section on this site for more help.
Dont forget to download the spreadsheet used in this tutorial so you can follow along with it.