时间计算器 — 加减小时、分钟、秒
This time calculator adds and subtracts multiple time values entered as hours, minutes, and seconds. Enter each time segment, choose whether to add or subtract it, and instantly see the total in HH:MM:SS format along with decimal hours, decimal minutes, and total seconds — useful for payroll, project tracking, and workout logs.
Result
Frequently Asked Questions
时间计算器是如何工作的?
时间计算器支持对时间进行加减运算。您可以输入两个时间点来计算时间差,也可以在某个时间点上加减小时、分钟或秒来得到新的时间点。支持处理跨午夜的情况(如 11:00 PM + 3 小时 = 2:00 AM)。
如何计算两个时间点之间的时间差?
输入开始时间和结束时间,计算器会自动计算差值并以小时、分钟、秒的格式显示。对于跨日的时间差(如从下午到次日早晨),可选择"跨日"选项,计算器会正确处理 24 小时制的进位。
如何将时间转换为十进制小时?
十进制小时 = 小时数 + 分钟数/60 + 秒数/3600。例如,2 小时 30 分 = 2 + 30/60 = 2.5 小时;1 小时 45 分 30 秒 = 1 + 45/60 + 30/3600 ≈ 1.758 小时。十进制格式便于计算工资(时薪 × 十进制小时数)。
时间单位的换算关系是什么?
1 天 = 24 小时;1 小时 = 60 分钟 = 3,600 秒;1 分钟 = 60 秒;1 周 = 7 天 = 168 小时;1 年 ≈ 365.25 天 = 8,766 小时(含闰年平均)。本计算器支持在这些单位间相互换算。
Time Addition Formula
Adding or subtracting time values follows a simple rule: convert everything to seconds, perform the arithmetic, then convert back to hours, minutes, and seconds.
Step 1 — Convert to seconds
Total Seconds = (hours × 3600) + (minutes × 60) + seconds
Step 2 — Add or subtract
Result = Time⊂1⊂ ± Time⊂2⊂ ± …
Step 3 — Convert back
Hours = ⌊Seconds / 3600⌋
Minutes = ⌊(Seconds mod 3600) / 60⌋
Seconds = Seconds mod 60
How to Add and Subtract Time
Use the calculator above by entering hours, minutes, and seconds for each time value. Toggle the + / −button to add or subtract that row's time from the running total. Add as many rows as needed.
Example: Shift duration
A worker starts at 8:30 AM and finishes at 5:15 PM with a 45-minute lunch break.
- Row 1 (+): 8 hours 45 minutes 0 seconds (8:30 AM to 5:15 PM = 8h 45m)
- Row 2 (−): 0 hours 45 minutes 0 seconds (lunch)
- Result: 08:00:00 — 8 hours of work
Example: Project time tracking
Combine multiple time logs across a day: 1h 20m, 2h 45m, and 0h 50m.
- Row 1 (+): 1:20:00
- Row 2 (+): 2:45:00
- Row 3 (+): 0:50:00
- Result: 04:55:00
Converting Time to Decimal
Decimal hours are often required for payroll, billing, or spreadsheet formulas. Converting is straightforward:
Decimal Hours = Total Seconds / 3600
Decimal Minutes = Total Seconds / 60
Example: 1 hour 30 minutes = 5400 seconds → 1.5 decimal hours or 90 decimal minutes.
Common Time Conversions Table
Use these reference values when converting between time formats:
| HH:MM:SS | Decimal Hours | Decimal Minutes | Total Seconds |
|---|---|---|---|
| 00:15:00 | 0.25 | 15 | 900 |
| 00:30:00 | 0.5 | 30 | 1,800 |
| 00:45:00 | 0.75 | 45 | 2,700 |
| 01:00:00 | 1.0 | 60 | 3,600 |
| 01:30:00 | 1.5 | 90 | 5,400 |
| 02:00:00 | 2.0 | 120 | 7,200 |
| 04:00:00 | 4.0 | 240 | 14,400 |
| 08:00:00 | 8.0 | 480 | 28,800 |
| 12:00:00 | 12.0 | 720 | 43,200 |
| 24:00:00 | 24.0 | 1,440 | 86,400 |
Related Tools
- Hours Calculator — Calculate total hours worked between start and end times
- Date Calculator — Find the difference between two dates or add days to a date
- Countdown Calculator — Count down the days, hours, and minutes to any future event