How to Work Out the Length of a Trip, a Shift or a Marathon

A start time and an end time are all you ever get, whether the question is a road trip, a night shift or a race finish. This guide works through each shape of the problem - same day, overnight, split in two, and measured to the minute - with the arithmetic shown all the way through.

By Johnson Ramzan · Updated November 7, 2026

Open the Time Duration Calculator

Just need the number? Enter the two times into the free time duration calculator and it returns the length in hours, minutes and seconds, overnight spans included. This guide teaches the method behind it, with examples for trips, shifts and races.
Home / Guides / Length of a Trip or Shift

"How long was it?" sounds like one question, but it hides three different ones. There is the span - the raw distance between the start and the end. There is the active time - the span minus stops and breaks. And there is the official time - what a time card, a race clock or a tachograph records, which may round or define the endpoints differently. Most arguments about length are really two people answering different versions of the question. Decide which one you need, then calculate.

For all three versions, the engine is the same: convert both times to minutes since midnight, subtract, convert back. What changes is only what you subtract afterwards and whether a day boundary sits inside the span.

The same-day span: a road trip

You leave at 8:15 AM and arrive at 6:40 PM. Convert: 8:15 AM is 495 minutes; 6:40 PM is 18:40, which is 1,120 minutes. Subtract: 1,120 - 495 = 625 minutes, which is 10 hours 25 minutes. That is the span, door to door. But it is not your driving time. If the trip included a 40-minute lunch stop and two 15-minute fuel stops, the stops total 1 hour 10 minutes, and the wheel time is 10:25 minus 1:10, which is 9 hours 15 minutes. Both numbers are honest; they answer different questions. The span tells you when to leave to arrive by dinner. The wheel time tells you how tired you will be when you get there.

The overnight span: a night shift

A shift from 9:00 PM to 5:30 AM breaks the naive subtraction, because the end (330 minutes) is smaller than the start (1,260 minutes). The fix is one line: when the end is earlier than the start, add a full day - 1,440 minutes - to the end before subtracting. 330 + 1,440 = 1,770, and 1,770 - 1,260 = 510 minutes, or 8 hours 30 minutes. Check it in pieces if you like: 9:00 PM to midnight is 3 hours, midnight to 5:30 AM is 5 hours 30 minutes, and the two pieces add to 8:30. Overnight spans are where most hand calculations fail, and they fail by exactly 24 hours or by going negative - both are the same missing step. Our companion guide on durations that fall on different days extends this fix to spans longer than a single night.

Close-up of a wristwatch face - How to Work Out the Length of a Trip, a Shift or a Marathon
The overnight case is the same subtraction with one extra day added to the end time - nothing else changes.

The split span: two pieces in one day

Split shifts, common in restaurants and care work, are two spans wearing one name. A server works 6:00 AM to 10:00 AM, then returns for 4:00 PM to 9:00 PM. Piece one is 4 hours. Piece two is 5 hours. The worked length is 9 hours, even though the day stretches across 15 hours from first start to last finish. Add the pieces; never subtract the first start from the last finish unless you genuinely want the stretch of the day. The same logic handles a trip with an overnight hotel stop: each driving day is its own span, and the trip's driving time is the sum.

The measured span: race times

Races add one wrinkle - the endpoints are recorded to the second and the start is not always yours. A marathoner crosses the start line at 7:02 AM and the finish at 11:47 AM: 707 - 422 = 285 minutes, or 4 hours 45 minutes. In big city races, the gun fires before you reach the line, so your official chip time uses your own start crossing instead. If the gun went at 7:00 and you crossed at 7:02, the 2-minute difference is real and belongs to the crowd, not to you. The calculation is identical either way; the skill is knowing which start time is actually yours.

The time-zone wrinkle: trips that cross a zone boundary

Clock times are local, and a long trip can change what "local" means mid-span. Drive from Chicago to Denver: you leave at 9:00 AM Central and arrive at 4:00 PM Mountain. The clocks suggest 7 hours, but Denver runs one hour behind Chicago, so the sun - and your body - experienced 8 hours. The rule is to convert both endpoints into one zone before subtracting: 9:00 AM Central is 8:00 AM Mountain, and 4:00 PM minus 8:00 AM is 8 hours on the road. Flights show the same effect with the digits pointing the other way: a flight out of New York at 8:00 AM that lands in Los Angeles at 11:00 AM Pacific looks like 3 hours by raw subtraction, but 8:00 AM Eastern is 5:00 AM Pacific, so the real time in the air is 6 hours. Whenever a span crosses a zone line, the raw clock subtraction is wrong by exactly the zone difference.

Gross length, net length, and why both matter

However you measure, keep the two versions separate in your notes: gross (the whole span) and net (the span minus unpaid or inactive time). A nurse's 12-hour shift with an unpaid 30-minute meal break is 12 hours gross and 11.5 net. A trucker's day may be 14 hours gross with 11 at the wheel. Payroll pays the net, schedules are built on the gross, and confusing them is how a week that felt like 50 hours pays like 44. When the span comes from two dates and times rather than a single day, the time duration calculator handles the day counting for you, and our guide to working out a flight duration covers the special case where time zones move the endpoints.

Try it the fast way

For any single span, the time duration calculator takes a start and an end - clock times or full dates - and returns the length split into days, hours, minutes and seconds, so overnight and multi-day spans need no manual day-adding. If your span is a working shift with a break inside it, the time calculator on the homepage and the hours tools linked there will take the break off the total for you as well.

Frequently asked questions

How do I work out a shift that crosses midnight?

Add 24 hours to the end time before you subtract. A shift from 9:00 PM to 5:30 AM becomes 1,260 minutes to 1,770 minutes (330 plus the 1,440 minutes of a full day), and the difference is 510 minutes, or 8 hours 30 minutes. Any span under 24 hours works with this single fix.

Does the length of a shift include the lunch break?

The raw span includes everything between clock-in and clock-out. Your paid length is the span minus unpaid breaks. An 8 hour 30 minute span with a 30-minute unpaid lunch is 8 hours of paid time. Report both numbers and label them, because schedules usually quote the span and payroll pays the net figure.

How long can a driving day be before it stops being sensible?

Professional truck drivers in the US are capped at 11 hours of driving inside a 14-hour window, and that is a useful ceiling for everyone. For a personal road trip, most people find 8 to 10 hours of wheel time is a full day; past that, fatigue makes the last hours the dangerous ones. Plan the trip length first, then the stops.

How do I get a race time from a start and finish clock time?

Subtract the start from the finish using the minutes method. A marathon started at 7:02 AM (422 minutes) and finished at 11:47 AM (707 minutes) took 285 minutes, or 4 hours 45 minutes. With chip timing, use your own chip start time rather than the gun time if the two differ.

What if the start and end are on different days?

Count the whole days between the two clock times first, then adjust for the clock difference. Friday 9:00 AM to Monday 5:00 PM is 3 whole days plus 8 hours, which is 80 hours. If the end clock time is earlier than the start clock time, the last day is partial and you subtract instead of add.

About the author
Johnson Ramzan builds and maintains every calculator on Time Calculator Tools himself, and he tests each one against worked examples he has done by hand before it is allowed near a reader. His guides follow US Department of Labor guidance on hours worked, overtime and rounding, and he writes them the way he would want a payslip explained to him: plain English, real numbers, and no step skipped. When a reader writes in with a shift pattern the tools handle badly, fixing it goes to the top of his list.
Last updated: November 7, 2026

Related guides

How to Work Out a Flight Duration From Departure and Arrival Times

Flight times with time zones in the mix: convert both ends to one zone before you subtract.

Read the guide

How to Calculate Duration When the Times Fall on Different Days

The anchor method for multi-day spans: whole days first, then the clock-time remainder.

Read the guide

How to Calculate the Duration Between Two Times

The core subtraction method, with borrowing, AM and PM, and overnight cases all worked through.

Read the guide

How to Calculate the Length of a Meeting or Event

Short spans measured properly, including setup, overrun and the meeting that ate the afternoon.

Read the guide