Counting days between two dates sounds simple until you factor in leap years, varying month lengths, weekends, holidays, and the question of whether the first day counts. Here's how it works, plus a free calculator that handles all the edge cases.
To count the days between two dates, subtract the earlier date from the later one. That's the whole idea. The tricky part is that "subtracting dates" isn't as straightforward as it sounds on a calendar, because:
The reliable way to compute it is to convert both dates to a common reference — typically the number of days since a fixed date, like January 1, 1970 (the Unix epoch). Then subtract the two reference numbers. Every programming language and calculator does this internally.
For a person doing it in their head, the practical method is to count forward from the earlier date to the later one, handling month boundaries as you go. It's tedious but reliable if you're careful. A calculator does it instantly.
Suppose you want to know how many days are between March 15 and July 4 of the same year.
| Step | Days | Running total |
|---|---|---|
| March 15 → March 31 | 16 | 16 |
| April (30 days) | 30 | 46 |
| May (31 days) | 31 | 77 |
| June (30 days) | 30 | 107 |
| July 1 → July 4 | 4 | 111 |
So there are 111 days between March 15 and July 4 of the same year. If a February 29 falls between the two dates, you'd add one more day for a total of 112.
Note that this count is exclusive of the start date — March 15 is not counted. If you wanted an inclusive count (both endpoints counted), it would be 113 days. That distinction matters, so let's look at it next.
There are two conventions for "days between," and they produce different answers:
The practical difference is always exactly one day. Knowing which convention applies matters when you're counting days for a contract, hotel booking, or court deadline.
For example, if you check into a hotel on March 15 and check out on March 18, you've stayed 3 nights — which is the exclusive count. Inclusive counting would say 4 days, but you're not paying for four nights, so exclusive is correct for billing.
A "business day" is usually defined as Monday through Friday, excluding weekends. Federal holidays in the relevant country are sometimes excluded too, but not always — the definition depends on the context.
The difference can be dramatic. From a Friday to the following Monday is:
Over a longer span — say, a month — the ratio is roughly 5 business days for every 7 calendar days. A 30-day period usually contains 22 business days, give or take a holiday or two.
Business days matter for shipping estimates, contract clauses ("within 10 business days"), banking (which counts 2–5 business days for transfers), and government deadlines.
A leap year adds one extra day — February 29 — to the calendar. Leap years occur in years divisible by 4, except for century years that aren't divisible by 400. So:
If a date range crosses a February 29, add one day to the result. Most calculators and programming functions handle this automatically, but it's the most common source of manual counting errors.
The "days between two dates" calculation shows up in more contexts than people realize:
How many days until a wedding, a vacation, a conference, or a birthday? Usually counted exclusive — "60 days to go" means 60 days from today to the event, not counting today.
Sprint durations, sprint planning, and project timelines are usually counted in business days, since teams don't work weekends. A "2-week sprint" is typically 10 business days.
Contract notice periods ("30 days' written notice"), statute of limitations windows, and court filing deadlines are almost always counted inclusive, and often business days. Getting the convention wrong can have real consequences.
Interest accrual, loan durations, and bond maturity dates all depend on day counts. Bond markets even use specific day-count conventions (30/360, actual/365, actual/actual) that have precise rules.
"How old is this building?" "How long has this company been in business?" These are often asked as years, but sometimes need to be calculated in days for precision.
"Arrives in 3–5 business days" is the standard estimate. If you order on a Friday, the first business day is Monday, so your package may not arrive until the following Wednesday or Thursday.
A related but slightly different problem: given a starting date and a number of days, weeks, months, or years, what's the resulting date? This is used for scheduling (30 days from today), renewal dates (one year from now), and deadline calculations.
The arithmetic is straightforward for days and weeks. For months and years, there's a subtlety: not all months have the same number of days. If you add one month to January 31, the result is typically February 28 (or 29 in a leap year), not March 3. Different conventions handle this differently — some roll forward, some clamp to the last day of the month.
The Date Difference Calculator has a separate tab for this: pick a start date, an amount, and a unit (days, weeks, months, years), and it computes the resulting date. Useful for figuring out when a deadline falls, when a subscription renews, or how long a contract runs.
For most "days between" questions, time zones don't matter — you're counting calendar days, not precise durations. But if you need an exact duration in hours or minutes (say, for a flight itinerary or a legal hearing that spans time zones), the calculation gets more involved.
A flight that departs Los Angeles at 10 AM and arrives in New York at 6 PM is a 5-hour flight, not an 8-hour one, because of the 3-hour time difference. A 24-hour period in one zone may overlap with two different calendar days in another.
For calendar-day calculations, this is usually not an issue. For precise durations across time zones, use a tool that lets you specify the zone for each date.