Days Between Dates Calculator

Need to know exactly how many days fall between two dates? Whether you're tracking a deadline, planning an event, or just curious how long ago something happened, a days between dates calculator gives you the answer in seconds. This page covers everything around that calculation: the formula behind it, how to handle business days, what leap years do to your math, and how to convert the result into weeks, months, or years. If you've ever second-guessed a date difference, you're in the right place.

Enter Details

Result

Pick two dates to count the days between.

Note — This result is an estimate. Talk to a healthcare provider for personalized guidance.

How to Calculate Days Between Two Dates

The basic idea is simple: subtract the earlier date from the later one. The result is the number of days between them. Most calculators and spreadsheet apps handle this automatically once you enter a start date and an end date.

In practice, though, a few things trip people up. Do you count the start date? Do you count the end date? Are weekends included? The answers depend on your specific purpose, and getting them wrong can throw off a project timeline or a legal deadline by a day or more.

Here's a quick rundown of how to approach it manually:

  • Write down your start date and end date in a consistent format (month/day/year works fine).
  • Convert both dates to a day count from a fixed reference point, or use a date serial number if you're working in a spreadsheet.
  • Subtract the start date's number from the end date's number.
  • Decide whether to add 1 to include both endpoints in your count.

For most everyday purposes, a calculator or a tool like Excel or Google Sheets handles all of this for you. But understanding the logic means you can catch errors when something looks off.

Days Between Dates Formula (End Date − Start Date)

The core formula is straightforward: Days = End Date − Start Date. That's it. Subtract the start from the end and you get the number of days in between.

In spreadsheet software, dates are stored as serial numbers. January 1, 1900 is day 1, January 2 is day 2, and so on. So when you type two dates into cells and subtract one from the other, you're literally subtracting two integers. The result is the day count.

For example, if your start date is March 1 and your end date is March 15 of the same year:

  • End date serial: 15
  • Start date serial: 1
  • Difference: 14 days

That gives you 14 days between those two dates, not counting either the start or the end as an extra day. If you want to count both endpoints (say, you're billing for every day including the first and last), you add 1 to get 15.

In Excel or Google Sheets, the formula looks like this: =B2-A2 where A2 is the start date and B2 is the end date. Format the result cell as a number rather than a date and you'll see the day count immediately.

Include or Exclude End Date in Calculation

This is where a lot of confusion comes from, and honestly it's worth taking a minute to think through which method your situation actually calls for.

When you subtract two dates, the default result excludes the end date. So from January 1 to January 5 gives you 4 days (the 1st, 2nd, 3rd, and 4th are counted; the 5th is not). That's the standard mathematical difference.

But some scenarios require you to count both the first and last day. Rental agreements, hospital stays, billing periods, and legal deadlines often work this way. In those cases, you add 1 to the result to include the end date.

MethodFormulaJan 1 to Jan 5 ResultCommon Use
Exclude end dateEnd − Start4 daysAge calculations, general countdowns
Include end dateEnd − Start + 15 daysRentals, billing, hospital stays

When in doubt, ask yourself: does the last day count as a full unit of time in this context? If yes, include it. If you're just measuring elapsed time (like how long since something happened), exclude it.

Business Days vs Calendar Days

Calendar days are every single day on the calendar: weekdays, weekends, holidays, all of them. Business days, on the other hand, typically mean Monday through Friday, excluding federal or regional holidays.

The difference matters a lot depending on what you're calculating. A shipping estimate, a contract deadline, or a payroll cycle all usually run on business days. A pregnancy due date or a quarantine period runs on calendar days.

Calculating business days manually is more involved. You have to:

  1. Count the total calendar days between the two dates.
  2. Subtract the number of Saturdays and Sundays in that range.
  3. Subtract any recognized holidays that fall on weekdays within the range.

The holiday part is what makes it complicated, because holidays vary by country, state, and company policy. A days between dates calculator that supports business day calculations usually lets you select a country or specify which holidays to exclude.

If you're doing this in Excel, the NETWORKDAYS function handles business days automatically. You provide a start date, an end date, and optionally a list of holiday dates, and it returns the count of working days.

Leap Years and Date Accuracy Explained

Leap years add an extra day (February 29) to the calendar every four years, with a few exceptions. The rule: a year is a leap year if it's divisible by 4, except for century years, which must be divisible by 400. So 2000 was a leap year, but 1900 was not.

For most short date range calculations, leap years don't matter much. But they do matter when your date range spans a February in a leap year, or when you're calculating something over multiple years.

Here's where accuracy gets real:

  • A regular year has 365 days.
  • A leap year has 366 days.
  • The average over a 400-year cycle works out to 365.2425 days per year.

Any good date difference calculator accounts for leap years automatically by working with actual calendar dates rather than assuming every year is 365 days. If you're building something manually, always verify that your logic handles February 29 correctly, especially for ranges that straddle a leap year boundary.

For precise scientific or financial calculations spanning many years, this distinction genuinely changes your results. For everyday use like counting down to a birthday or a vacation, the calculator handles it without you needing to think about it at all.

Calculate Weeks, Months, and Years Between Dates

Once you have the number of days between two dates, converting to other units is pretty easy for weeks and a bit trickier for months and years.

Weeks: Divide the day count by 7. A span of 28 days equals exactly 4 weeks. If there's a remainder, you have some partial week left over.

Months: This one's messier because months aren't all the same length. You can't just divide by 30 and call it accurate. The right approach is to count how many calendar months fall between the two dates, then handle the remaining days separately. From January 15 to April 3 is 2 full months plus 19 days, not a clean number.

Years: Same idea. Divide by 365.25 if you want a rough decimal, or count actual calendar years and handle leftover months and days separately for precision.

Most calculators display results in a combined format: something like

Countdown and Time Difference Calculations

A countdown is just a days between dates calculation where one of the dates is today. You set your target date, the calculator finds today's date automatically, and subtracts to give you how many days remain.

Countdowns are useful for all kinds of things: days until a vacation, days until a product launch, days until a lease ends. Some calculators also break the result down into hours, minutes, and seconds for a more dramatic effect, which works well for event websites or personal milestone trackers.

Time difference calculations can also run in reverse. Instead of counting forward to a future date, you're counting backward to find how long ago something happened. How many days since your last workout? How many days since a contract was signed? Same math, just flipping which date is the "start" and which is the "end."

A few practical tips for countdown calculations:

  • Make sure the calculator uses your local time zone when pulling today's date, especially if you're crossing midnight or working internationally.
  • If your deadline has a specific time (not just a date), you'll want a calculator that handles hours and minutes too.
  • For recurring events, note the day of the week your target date falls on so you're not caught off guard.

Common Use Cases for Date Difference Calculator

People reach for a date difference calculator in all kinds of situations. Some are professional, some are personal, and a few are just satisfying to know.

  • Project management: Figuring out how many days (or business days) are left before a deliverable is due, or calculating how long a phase of work actually took.
  • Legal and financial deadlines: Contracts often specify a number of days for notice periods, payment terms, or response windows. Getting these right matters.
  • Age calculations: How old is someone in days, weeks, or months? Parents of young children use this constantly; so do doctors and researchers.
  • Travel planning: How many nights is the trip? How many days until departure? How long is the layover?
  • Health and fitness: Tracking how many days into a program you are, or calculating a due date based on a last menstrual period.
  • Rental and billing periods: Landlords, car rental companies, and subscription services all need accurate day counts to bill correctly.
  • Historical research: How many days between two historical events? How long did a particular period last?

Whatever your reason, a reliable date difference calculator removes the guesswork and the manual counting. You get an accurate number fast, and you can adjust for business days, end date inclusion, or other specifics depending on what the situation calls for.

Other Other Calculators

Explore all