How to Use
- Select the start date
Choose the beginning date of the period you want to measure.
- Select the end date
Choose the ending date of the period.
- View the result
Click Calculate to see the number of days between the two dates in multiple units.
What is a date interval?
A date interval is the length of time between two dates, expressed in days. Because the calendar mixes 30- and 31-day months and February has 29 days in a leap year, doing the math in your head is error-prone. This calculator counts the difference between two dates exactly, based on the real Gregorian calendar.
Typical uses include:
- Countdowns (D-day): see at a glance how many days remain until an exam, a wedding, a due date, or an anniversary.
- Contract and employment periods: lease terms, length of service, probation periods, the end of an interest-free installment plan, and other legal or administrative durations.
- Business days: count only weekdays, excluding weekends, when setting project schedules or delivery deadlines.
By default the calculator includes the start date and excludes the end date. If you want to count both endpoints, turn on the 'Include End Date' option.
Formula
The total number of days between two dates is found from the difference in their midnight timestamps.
Total days = (end date − start date) ÷ 86,400,000 ms
For example, from 2024-01-01 to 2024-03-01 there are 31 days in January + 29 days in February (a leap year) = 60 days. Turning on 'Include End Date' adds 1, giving 61 days.
Business days are counted by stepping forward one day at a time from the start date, skipping Saturdays and Sundays.
Weekdays = total days − weekend days
Conversions to weeks, months, and years use averages: weeks = ⌊days ÷ 7⌋, months ≈ days ÷ 30.44, years ≈ days ÷ 365.25 (with leap-year correction).