Excel Formula: Add hours minutes seconds to time
Supposing there is a list of time values in Excel, now you want to add 3 hours 45 minutes and 20 seconds to the time values, Excel provides two formulas to help you.
Formula 1
Generic formula:
Start_time+hours/24+minutes/1440+seconds/86400 |
Arguments
Start_time: the time you used to add hours, minutes and seconds. |
Hours, minutes, seconds: numbers that indicate the hours, minutes, or seconds you want to add to time. They can be both of whole numbers and decimal numbers. |
Return value
Return a value in time format.
How this formula work
Take instance, to add hours, minutes, and seconds list in cell C3:E3 to the time in cell B3, please use below formula:
=B3+C3/24+D3/1440+E3/86400 |
Press Enter key to get the end time.
Explanation
One day contains 24 hours, or 1440 minutes, or 86400 seconds, then one hour is 1/24 a day, one minute is 1/1440 a day, and one second is 1/86400 a day.
Formula 2
Generic formula:
Start_time+TIME(hours,minutes,seconds) |
Arguments
Start_time: the time you used to add hours, minutes and seconds. |
Hours, minutes, seconds: numbers that indicate the hours, minutes or seconds you want to add to time. In this formula, if the numbers which represent the hours, minutes or seconds are decimal numbers, it takes it as whole number when calculation. For example, 10.5 hours will be counted as 10. |
Return value
Return a value in time format.
How this formula work
Take instance, to add hours, minutes and seconds list in cell C8:E8 to the time in cell B8, please use below formula:
=B8+TIME(C8,D8,E8) |
Press Enter key to get the end time.
Explanation
Generally, TIME function is used to convert the decimal numbers to a time in the format hh:mm:ss. Here in this formula, it converts the numbers (10 hours, 12 minutes, and 75 seconds) to a time 10:12:17. Therefore, the whole formula =B8+TIME(C8,D8,E8) will be converted to: 12:56:09+10:12:75.
Remark
1. If you want to subtract the minutes from time, you can combine the MOD function with above formulas:
MOD(Start_time-hours/24-minutes/1440-seconds/86400,1)
Or
MOD(Start_time-TIME(hours,minutes,seconds),1)
In general, it does not allow the negative time in Excel, using the MOD function to flip the negative values to positive will get a correct time.
2. If the result is over 24 hours, just format the result as [h]:mm:ss format in the Custom section under Number tab of the Format Cells dialog.
Sample File
Relative Formulas
- Get Or Calculate Age From Birth Date In Excel
In Excel, there are some useful functions, such as YEARFRAC or DATEDIF which can help you to get the age from the birthday quickly and easily. - Extract Or Get Date Only From The Datetime In Excel
To extract only date from a list of datetime cells in Excel worksheet, the INT, TRUNC and DATE functions can help you to deal with this job quickly and easily. - Get Week Number From Date In Excel
In Excel, how could you get week number from the given date quickly and easily? Normally, the WEEKNUM function can help you to solve this task as quickly as possible. - Get Work Hours Between Two Dates In Excel
The NETWORKDAYS function in Excel can help you to get the net workdays between two dates, and then multiply the number of working hours per workday to get the total work hours.
Relative Functions
- Excel Date Function
DATE function can help us to combine year, month and day numbers from separate cells to a valid date. - Excel WEEKDAY Function
WEEKDAY function returns an integer number from 1 to 7 to represent the day of the week for a given date in Excel. - Excel WORKDAY Function
The WORKDAY is used to add a specified number of workdays to a started date and returns the future or past date in a serial number format. - Excel WORKDAY.INTL Function
WORKDAY.INTL function adds a specified number of workdays to a start date and returns a workday in the future or past. - Excel YEAR Function
The YEAR function returns the year based on the given date in a 4-digit serial number format.
The Best Office Productivity Tools
Kutools for Excel - Helps You To Stand Out From Crowd
Kutools for Excel Boasts Over 300 Features, Ensuring That What You Need is Just A Click Away...
Office Tab - Enable Tabbed Reading and Editing in Microsoft Office (include Excel)
- One second to switch between dozens of open documents!
- Reduce hundreds of mouse clicks for you every day, say goodbye to mouse hand.
- Increases your productivity by 50% when viewing and editing multiple documents.
- Brings Efficient Tabs to Office (include Excel), Just Like Chrome, Edge and Firefox.