How to calculate time duration
Subtract the start time from the end time. If the minutes don't subtract cleanly, borrow 60 minutes from the hours. Convert both times to 24-hour format to avoid AM/PM confusion.
Example: 9:15 AM to 5:40 PM
- Convert to 24-hr: 09:15 to 17:40
- Subtract minutes: 40 − 15 = 25 min
- Subtract hours: 17 − 9 = 8 hours
- Result: 8 hours 25 minutes (= 8.42 decimal hours)
Time duration formula
duration = end time − start time
If end < start, add 24 hours to end (crosses midnight)
Midnight handling: if the end time appears earlier than the start time (e.g., 10 PM to 6 AM), add 24 hours to the end. Example: 22:00 to 06:00 → add 24 → 30:00 − 22:00 = 8 hours.
For conversions between units: 1 minute = 60 seconds, 1 hour = 60 minutes = 3,600 seconds, 1 day = 24 hours = 1,440 minutes = 86,400 seconds.
Common time durations
| Event | H:M | Minutes | Seconds |
|---|---|---|---|
| Standard work shift | 8:00 | 480 | 28,800 |
| School day (K–12) | 6:30 | 390 | 23,400 |
| Full-time work week | 40:00 | 2,400 | 144,000 |
| Night's sleep (avg) | 8:00 | 480 | 28,800 |
| Marathon (average) | 4:30 | 270 | 16,200 |
| Full day | 24:00 | 1,440 | 86,400 |
| Full week | 168:00 | 10,080 | 604,800 |
Decimal time conversion
Payroll systems typically use decimal hours instead of hours:minutes. To convert: decimal hours = hours + (minutes ÷ 60).
| Minutes | Decimal hours |
|---|---|
| 15 min | 0.25 |
| 30 min | 0.50 |
| 45 min | 0.75 |
| 5 min | 0.08 |
| 10 min | 0.17 |
| 20 min | 0.33 |
| 25 min | 0.42 |
| 40 min | 0.67 |
| 50 min | 0.83 |
| 55 min | 0.92 |
Time zones and duration
This calculator assumes both times are in the same time zone. For cross-timezone durations, convert both times to UTC first, then subtract. A 3 PM ET departure and 6 PM PT arrival (on the same day) is actually a 6-hour flight, not 3 hours — ET is 3 hours ahead of PT, so 3 PM ET = 12 PM PT, and 12 PM to 6 PM = 6 hours.
Time duration for payroll
For hourly employees, time duration directly determines pay. The standard workflow:
- Calculate clock-in to clock-out duration for each day.
- Subtract unpaid breaks (typically 30-min lunch).
- Convert to decimal hours (e.g., 7h 30m = 7.5).
- Multiply by hourly rate for daily gross pay.
- Sum the days for the pay period.
- Apply overtime rate (1.5×) for hours over 40/week in most US states.
Use our Salary to Hourly Calculator to convert between pay structures, or the Salary Calculator for a full take-home pay estimate.
Frequently asked questions
How do I calculate hours between two times?
Subtract the start time from the end time. If the minutes don't subtract cleanly, borrow an hour (60 minutes) from the hours. Example: 5:45 PM − 9:30 AM. Step 1: Convert to 24-hour: 17:45 − 09:30. Step 2: Subtract minutes: 45 − 30 = 15. Step 3: Subtract hours: 17 − 9 = 8. Result: 8 hours 15 minutes (8.25 decimal hours). If the minutes require borrowing: 5:15 − 2:45 → borrow 60 min: 4:75 − 2:45 = 2 hours 30 minutes.
How do I convert hours and minutes to decimal?
Divide the minutes by 60, then add to hours. Example: 8 hours 30 minutes = 8 + (30 ÷ 60) = 8.50 hours. 7 hours 15 minutes = 7.25. 6 hours 45 minutes = 6.75. Quick reference: 15 min = 0.25, 30 min = 0.50, 45 min = 0.75. This conversion is essential for payroll timesheets where pay is calculated on decimal hours, not hours:minutes.
How do I calculate hours worked for payroll?
Calculate duration between clock-in and clock-out, subtract unpaid breaks (usually 30 minutes for lunch), then convert to decimal hours. Example: 8:00 AM to 5:00 PM with 30-minute lunch = 9 hours − 0.5 hours = 8.5 hours worked. Multiply by hourly rate for gross pay: 8.5 × $20/hr = $170. For bi-weekly payroll, sum each day's decimal hours. Overtime (over 40 hrs/week in most states) is 1.5× hourly rate.
How many minutes are in X hours?
Multiply hours by 60. Common conversions: 1 hour = 60 min, 2 hours = 120 min, 3 hours = 180 min, 8 hours = 480 min, 24 hours = 1,440 min, 1 week (168 hrs) = 10,080 min. For half-hour increments: 1.5 hrs = 90 min, 7.5 hrs = 450 min. To convert minutes to hours, divide by 60: 200 min ÷ 60 = 3.33 hours = 3 hours 20 minutes.
How do I calculate time across midnight?
Add 24 hours to the end time, then subtract the start. Example: shift from 10:00 PM to 6:00 AM. Start: 22:00, End: 6:00 + 24 = 30:00. Duration: 30:00 − 22:00 = 8 hours. Most time calculators handle this automatically when they detect the end time is earlier than the start time. For very long durations (multi-day), count full 24-hour periods separately and add the partial day.
What is elapsed time?
Elapsed time is the total duration that has passed between two specific moments — the time interval or 'how long did this take.' It's the same as duration. Example: a race started at 9:00 AM and finished at 10:35 AM — the elapsed time is 1 hour 35 minutes. Elapsed time is always a positive value (duration) — it doesn't matter which direction time moves, only the gap between start and end.
How do I add hours and minutes?
Add hours to hours and minutes to minutes separately. If minutes total 60 or more, carry to hours. Example: 2 hours 45 minutes + 1 hour 30 minutes. Minutes: 45 + 30 = 75 min → 1 hour 15 min. Hours: 2 + 1 + 1 (carried) = 4 hours. Result: 4 hours 15 minutes. For decimal: 2.75 + 1.50 = 4.25 hours, same answer. Our calculator handles this automatically.
How do I subtract time?
Subtract minutes from minutes and hours from hours. If minutes don't subtract cleanly, borrow 60 minutes from the hours. Example: 5 hours 20 min − 2 hours 45 min. Minutes: 20 − 45 can't do, borrow: 4 hours 80 min − 2 hours 45 min = 2 hours 35 minutes. Works the same as borrowing in regular subtraction, just with base 60 instead of base 10.
How many hours is 9am to 5pm?
8 hours. 9 AM (09:00) to 5 PM (17:00) = 17 − 9 = 8 hours exactly. This is the classic 'nine-to-five' workday. If you take a 30-minute unpaid lunch, you work 7.5 hours. With a 1-hour lunch, 7 hours. A true 40-hour work week is 5 nine-to-fives with 30-minute breaks (5 × 7.5 = 37.5) or 4 ten-hour days, or 40 hours with shorter breaks.
How do I convert minutes to hours?
Divide minutes by 60. Examples: 30 min = 0.5 hours, 90 min = 1.5 hours, 120 min = 2 hours, 500 min = 8.33 hours (8 hours 20 min), 1,440 min = 24 hours. To convert to hours:minutes format, use the whole number for hours and the remainder × 60 for minutes: 500 ÷ 60 = 8 remainder 20 → 8 hours 20 minutes. Our Time Duration calculator converts in both directions instantly.