Hours Calculator

Add and subtract durations in HH:MM or work out hours between two times, night shifts included.

How to use

  1. Choose the mode: add and subtract durations, or measure the time between two clock times.
  2. Type each duration as HH:MM, adding as many lines as you need and switching any line to subtract.
  3. Read the total in HH:MM and in decimal hours — the format timesheets, invoices and payroll expect.

About this tool

Clock time is base 60, which is exactly why adding hours by hand goes wrong: 2:45 plus 1:30 is 4:15, not 4.75 and not 3.75. This calculator has two modes for the two situations that actually come up. The first adds and subtracts a list of durations — every line can be switched from add to subtract, so a week of tracked work minus an hour of lunch is a single sum. The second takes a start time and an end time, understands shifts that run past midnight, and subtracts an optional break in minutes to give the hours actually worked.

Everything is converted to whole minutes before any arithmetic happens: hours times 60 plus minutes. The total is summed as an integer, then formatted back to HH:MM, which means no floating-point drift and no rounding surprises even across dozens of lines. The decimal figure next to it is simply the total minutes divided by 60 and rounded to two places — 4:15 becomes 4.25 — because that is the unit timesheets, invoices and payroll systems work in. When the end time is earlier than the start time, the tool adds 24 hours automatically, so 23:00 to 02:30 correctly returns 3:30 instead of a negative number.

It is built for the practical cases: a freelancer totalling billable hours before invoicing, an employee checking a timesheet or an overtime bank, a night-shift worker verifying a shift that crosses midnight, a student adding study blocks. The result is arithmetic, not a labour-law ruling — night premiums, rounding policies and overtime multipliers vary by contract and country and are not applied here. Every calculation runs in your browser, so the hours, shifts and clients you type never leave your device.

The formula

Each duration becomes whole minutes (hours × 60 + minutes), the signed values are summed, and the total is formatted back as HH:MM. Decimal hours are total minutes ÷ 60 rounded to two decimals, so 4:15 is 4.25. For two clock times the difference is end − start in minutes; if the end is earlier than the start, 1,440 minutes (24 h) are added to cross midnight, and the break in minutes is subtracted afterwards.

Frequently asked questions

How do I add 2:45 and 1:30 correctly?

Convert both to minutes: 165 + 90 = 255 minutes, which is 4:15. Adding them as decimals (2.45 + 1.30) gives the wrong answer because minutes run to 60, not to 100.

What are decimal hours?

Decimal hours express minutes as a fraction of an hour: 4:15 is 4.25 hours and 7:30 is 7.5 hours. Payroll systems, timesheets and hourly invoices almost always use this format.

Does it handle a shift that crosses midnight?

Yes, automatically. If the end time is earlier than the start time the calculator adds 24 hours, so 23:00 to 02:30 returns 3:30.

Can the total be negative?

Yes. If you subtract more than you add, the total is shown with a minus sign — useful when checking an hours bank that is in the red.

Does this calculate overtime pay or night premiums?

No. It returns the exact duration only. Overtime multipliers, night premiums and rounding rules depend on your contract and local labour law and are not applied.

Do my hours leave my browser?

No. The arithmetic runs in JavaScript on your device and nothing you type is transmitted, logged or stored.

Related tools

Long links? Shorten them for free

Vai.la turns any URL into a short link with click statistics, QR Code and your own biolink.

Vai.la is not responsible for how the tools are used or for decisions made based on their results.