U

Hours Calculator

Compute work hours, shift duration or elapsed time between two clock times, including periods that cross midnight, as total minutes, hours + minutes and decimal hours.
Start Time
9
023
0
059
End Time
17
023
0
059
Period Type

Work Duration

Breakdown

Remaining minutes
0minutes
Total minutes
0minutes
Decimal hours
0h

Key Assumptions

  • Times are entered in 24-hour format: hours run from 0 (midnight) to 23, and minutes from 0 to 59 — 3:15 PM is entered as 15 hours and 15 minutes.
  • In 'Same day' mode, an end time earlier than the start time is interpreted as crossing midnight, so 24 hours are added automatically.
  • In 'Next day' mode, exactly 24 hours are added to the end time, covering shifts that end on the following calendar day.
  • The calculator works in whole minutes and ignores seconds and any actual seconds-only clock readings.
  • Clock changes from daylight saving time are not considered; every day is treated as a plain 24 hours.

Formula Used

durationMin = (endHour×60 + endMin + [1440 if 'Next day'] − (startHour×60 + startMin)) if durationMin < 0, add 1440 (overnight wrap-around) Total hours = floor(durationMin / 60) Remaining minutes = durationMin mod 60 Decimal hours = durationMin / 60, rounded to 2 places
Embed this calculator on your website

Add this embed page to your site — visitors use the calculator right from your page.

Time is the one resource everyone budgets, and the Hours Calculator exists to answer a deceptively simple question: exactly how long is the span between two clock times? Filling in a timesheet, scheduling a shift, logging a workshop or planning a journey all come down to the same arithmetic, and doing it by hand in your head is where errors creep in. This tool takes your start time and end time, handles the awkward cases such as overnight shifts automatically, and returns the answer in the three forms people actually need: total minutes, hours plus minutes, and decimal hours.

What Is an Hours Calculator?

An hours calculator is a small utility that subtracts one clock time from another and reports the difference as a duration. The inputs are the two moments themselves — a start and an end, each split into hours and minutes. The output is never another clock time; it is an amount of elapsed time, like 8 hours, 480 minutes or 8.67 hours. The same computation sits behind a huge range of real-world questions: how long was my shift, how many billable hours did I spend on this project, how long is the drive from a 9:00 appointment to a lunch break, or how much screen time does my study session actually cover. Because the underlying arithmetic is so common, a reliable calculator feels trivial, yet the details — 24-hour clocks, minutes past the hour, and periods that wrap past midnight — trip people up constantly.

How to Use This Hours Calculator

Using the tool takes a few seconds. In the Start Time group, set the hour and the minute the period begins. In the End Time group, do the same for the end of the period. Both use a 24-hour clock, so the afternoon is entered as hours 12 through 23 — 3:15 PM becomes hour 15, minute 15. Then pick a period mode. Same day fits anything that starts and ends on one calendar day. Next day adds a full 24 hours to the end time, which is the right setting for a night shift that is described by two different calendar days, such as Monday evening to Tuesday morning. The results update as you move the sliders, so comparing a one-hour commute against a two-hour one is as easy as dragging the values.

The Math Behind the Calculator

Time subtraction is easier than it looks when both times live on the same 24-hour clock. The trick is to convert each clock time into its position in the day, measured in minutes. A start of 09:00 becomes 540 minutes; an end of 13:45 becomes 825 minutes. The duration is simply end minus start — here 285 minutes, or 4 hours and 45 minutes. The calculator performs that conversion for you, then applies one refinement: if the end time is numerically earlier than the start, the period must span midnight, so a full 1,440 minutes is added before subtracting. This single rule makes overnight calculations automatic.

  1. Convert the start time to minutes: startHour × 60 + startMin.
  2. Convert the end time to minutes: endHour × 60 + endMin. Add 1,440 in Next-day mode.
  3. Subtract the start from the end.
  4. If the result is negative, add 1,440 so the period wraps around midnight correctly.
  5. Split the total into full hours and remaining minutes, and divide by 60 for decimal hours.

Reading the Results

The headline figure is Total hours, the number of complete 60-minute blocks in your period. Beside it, the remaining minutes tells you what is left over after those full hours are removed, so a 6-hour-and-15-minute period always displays as 6 hours and 15 minutes. Total minutes shows the same duration as a single number — 375 instead of 6 hours and 15 minutes — which is convenient when you need a figure to feed into another calculation, such as minutes for a timesheet or for comparing lengths. The last output, decimal hours, expresses the whole period as a fraction of an hour, so the same example becomes 6.25 hours.

All four figures are derived from the exact same duration, so they never disagree with one another. A period of 9:30 to 14:20 always returns 4 hours and 50 minutes, 290 total minutes and 4.83 decimal hours no matter how many times you check. Because the calculator recomputes live as you adjust either end of the period, you can quickly explore how moving a single minute shifts the outcome.

Work Hours, Shifts and the Minimum Wage Math

The most popular use is payroll: filling in how many hours you actually worked. A standard working day of 09:00 to 18:00 with an hour of breaks is eight billable hours, but the way the figure is expressed matters. If your employer's system stores decimal hours, 15 minutes must be entered as 0.25, and a nine-hour-and-15-minute day becomes 9.25. The hours calculator gives you that decimal form directly, eliminating the classic mistake of writing 9.15 and being paid 9 hours and 15 minutes instead of 9 hours and 9 minutes. Experienced freelancers book time in hours as decimal numbers for exactly this reason: invoices that carry minutes are error-prone, so they round every session to the nearest tenth of an hour before billing. The same habit — checking the decimal hours figure before sending the client their invoice — removes most billing disputes.

Shifts That Cross Midnight

Night shifts, overnight flights and events that end after 00:00 are where most manual time calculations go wrong. A shift from 22:00 to 06:00 looks, at a glance, like four hours if you simply subtract the hours, because no one subtracts 22 from 6 without remembering the day change. The calculator never forgets. In same-day mode it detects that the end precedes the start and silently spans midnight, returning the correct eight hours. In the next-day setting, where the shift is explicitly described as starting on one date and ending on another, the 24-hour shift gives the same result through a different route. Which mode you choose is really about how you describe your roster; the result is identical for a single overnight.

Where You Can Apply It: Quick Reference

PeriodClock formatDuration
Standard office day09:00 → 17:008 h 0 min
Early shift without lunch06:00 → 14:008 h 0 min
Short evening meeting18:30 → 19:1545 min
Night guard turn22:00 → 06:008 h 0 min
Double shift06:00 → 20:3014 h 30 min

Notice the midnight case in the table: both the day shift and the night guard shift last eight hours, but one of them crosses a day boundary. The calculator's wrap-around rule is exactly what turns the night example from a head-scratcher into a routine lookup.

Decimal Hours vs. Hours and Minutes

Two representation systems dominate. In hours plus minutes, time is reported as 4 hours and 45 minutes — the format people use in conversation and on most timesheets. In decimal hours, the same duration is 4.75 hours — the format used by wages, spreadsheets and accounting software. The conversion is simple: take the minutes, divide by 60 and add that to the hours. Fifteen minutes becomes 0.25, thirty minutes 0.5, forty-five minutes 0.75. The calculator gives you both reading immediately. Remember that 0.5 hours is never 50 minutes; it is exactly 30. Distinguishing the two is where nearly all payroll errors originate.

Common Mistakes to Avoid

Getting the results right is easy when you avoid these regular pitfalls. First, the 12-hour trap: verify which 12:00 you mean. Noon is 12 in 24-hour time, midnight is 0, and 12 AM to 12 PM is a different 12-hour cycle entirely. Second, check the order of your entries. A start of 17:00 and an end of 09:00 same day means an overnight, which the calculator handles, but an accidental swap of start and end in the same-day mode flips the meaning. Third, don't confuse the period length with the day length. Tasks that run 14 hours cannot be entered in the next-day mode's two-day window without care; the mode adds a fixed 24 hours, which is correct, but only when your period genuinely spans a day boundary. Fourth, be consistent with units: hours and minutes are not decimal hours, so decide who is reading the number — your timesheet or your spreadsheet.

Assumptions and Limits

  • Times are whole minutes on a 24-hour clock; seconds are not entered, so 17:00:45 is treated as exactly 17:00.
  • Days are exactly 24 hours. Daylight saving transitions on weekends shift the clock and are simply not modelled.
  • Breaks are never deducted automatically. Subtract lunch or breaks from the result yourself when tracking paid time.
  • The midnight wrap-around is applied whenever the end time is earlier than the start, in both modes.

Because these rules are explicit, the tool behaves predictably. If your actual situation differs from one of the assumptions, the difference is always a simple adjustment — subtract a break, or shift the entries — that you can do once you know what the calculator is showing you.

FAQs

Related Calculators