Date Difference Calculator
Days, weeks, months and years between any two dates. Business days, leap-year aware, DST safe, ISO 8601 dates. For age, contracts, project planning.
Date Difference Calculator - Calculate Days Between Dates
Counting time between two calendar dates sounds trivial until you actually do it: months have 28, 29, 30, or 31 days; the Gregorian leap rule excludes century years that are not divisible by 400 (so 1900 is not a leap year but 2000 is); daylight-saving transitions shorten or lengthen one day every spring and fall in most of North America and Europe; and 27 leap seconds have been inserted into UTC since 1972. This calculator normalizes both inputs to ISO 8601 (YYYY-MM-DD) at midnight local time, subtracts as a count of calendar days (so DST never produces a fractional day), and then re-expresses the gap as a calendar-aware breakdown of years, months and days using the same convention as the EDATE function in spreadsheets — if the start day-of-month does not exist in the end month (e.g. Jan 31 to Feb 28), the breakdown clamps to the last day. Business-day counting follows the Western 5-day week (Mon-Fri) and does not exclude regional public holidays, which vary by country and would require a locale-specific holiday list. All processing is client-side so the date never leaves your browser — useful for HR, legal and medical contexts where data residency matters.
What is a Date Difference Calculator?
A date difference calculator is a tool that calculates the exact time duration between two dates. It provides the difference in multiple units:
- Total days between dates
- Breakdown by years, months, and days
- Number of weeks
- Business days (excluding weekends)
- Weekend days only
- Total hours, minutes, and seconds
The calculator is useful for:
- Calculating age from birthdate
- Project duration planning
- Event countdowns
- Leave/vacation day calculations
- Historical date analysis
- Anniversary tracking
- Contract period calculations
How does the calculator work?
The date difference calculator works by:
1. Taking two dates as input (start date and end date)
2. Calculating the total number of days between them
3. Breaking down the difference into:
- Years: Complete years between dates
- Months: Remaining complete months
- Days: Remaining days after years and months
4. Calculating business days (Monday-Friday)
5. Identifying weekend days (Saturday-Sunday)
6. Converting to total hours, minutes, and seconds
Key features:
- Accurate leap year handling
- Proper month-end date handling
- Timezone-aware calculations
- Business day calculation (5-day workweek)
- Multiple output formats
- Instant calculation
What are business days?
Business days (or working days) are weekdays excluding weekends:
- Monday through Friday = Business days
- Saturday and Sunday = Weekend days (excluded)
Why business days matter:
- Project planning (estimate workdays needed)
- Leave calculations (count working days off)
- Delivery estimates (business day shipping)
- Payment terms (net 30 business days)
- SLA agreements (response within X business days)
- Contract deadlines
Example:
- Start: Monday, Jan 1
- End: Friday, Jan 12
- Total days: 12 days
- Business days: 10 days (excluding 2 weekends)
- Weekend days: 2 days
By default this counts a standard 5-day workweek (Mon-Fri). To also skip national public holidays, see the working-days mode below.
Does the end day count? Inclusive vs exclusive day counting
This is the single most common reason a date result looks '1 day off', and both answers are legitimate depending on context.
Exclusive (default): the calculator counts the gap BETWEEN the two dates. From Jan 1 to Jan 2 is 1 day, because you are measuring the distance you travel, not the dates you touch.
Inclusive (tick 'Include end day'): the end date is counted as a full day, so the same Jan 1 to Jan 2 becomes 2 days. Use this when both endpoints are 'used' — hotel nights vs days, a 30-day notice period that includes the final day, billing cycles, leave/vacation days where you are away on both the first and last day, or rental and event durations.
Rule of thumb:
- 'How many days until X?' or 'time elapsed' = exclusive (leave it unchecked).
- 'How many days am I booked/charged/on leave?' = inclusive (check the box).
The 'Include end day' option adds exactly 1 day and updates every figure — total days, weeks, the year/month/day breakdown and the working-days count — so they all stay consistent.

How do I count working days excluding public holidays?
Removing only Saturdays and Sundays overstates working days by the number of public holidays in the span — a real problem for 'net 30 business days' terms, SLA response windows, statutory notice periods and payroll accruals that are legally defined in working days.
Use the working-days mode:
1. Pick a holiday region (United States, United Kingdom, Canada or Australia). The tool knows that region's national public holidays for every year your range covers, including moving holidays like US Thanksgiving (4th Thursday of November) or the UK spring bank holiday (last Monday of May).
2. The 'Business Days' box is relabelled 'Net Working Days' and shows a 'minus N holidays' note so you can see exactly how many statutory days were removed.
3. For company-specific closures, choose 'Custom holidays only' (or combine a region with custom dates) and enter one date per line in YYYY-MM-DD format.
Holidays that already fall on a weekend are not double-counted, and the weekend total still reconciles with the day total. All holiday dates are computed in your browser — nothing is sent to a server. Note that observed/substitute days (when a fixed holiday lands on a weekend) and regional or state-level holidays are not added automatically; add those via custom holidays if you need them.
How to calculate age using this tool?
To calculate age from birthdate:
1. Set 'Start Date' to your birthdate
2. Set 'End Date' to today (click 'Today' button)
3. Click 'Calculate'
4. View your exact age in the breakdown:
- Years: Your age in complete years
- Months: Additional months
- Days: Additional days
Example:
- Birthdate: January 15, 1990
- Today: October 20, 2025
- Result: 35 years, 9 months, 5 days
- Total days: 13,062 days
You can also see:
- Total weeks lived
- Total hours lived
- Net working days since birth (with the holiday region option)
This is more precise than simple year calculations because it accounts for exact months and days.
How accurate is the calculation?
The date difference calculator is highly accurate:
Accuracy features:
- Accounts for leap years correctly
- Handles month-end dates properly
- Respects different month lengths (28-31 days)
- Uses precise day counting
- Timezone-aware (uses browser timezone)
- Millisecond precision
Leap year handling:
- Correctly identifies leap years (divisible by 4)
- Exception: Years divisible by 100 (not leap)
- Exception to exception: Years divisible by 400 (leap)
- Examples: 2000 (leap), 1900 (not leap), 2024 (leap)
Month-end handling:
- Jan 31 + 1 month = Feb 28/29 (last day of Feb)
- Different month lengths handled correctly
- No date overflow errors
Business day calculation:
- Accurate weekday/weekend identification
- Accounts for date ranges crossing multiple weeks
- Correct for any year/month combination
Limitations:
- Public holidays not excluded from business days
- Uses Gregorian calendar only
- Historical dates before 1582 may have calendar differences
Common use cases for date difference calculation?
The date difference calculator has many practical applications:
Personal Use:
- Calculate your exact age
- Count days until birthday/anniversary
- Track relationship milestones
- Plan vacation days
- Count days since special events
Business Use:
- Project duration planning
- Employee tenure calculation
- Contract period verification
- Invoice due date calculation
- Warranty period tracking
- Loan/mortgage duration
Education:
- Semester/term length
- Days until graduation
- Study schedule planning
- Attendance day counting
Health & Fitness:
- Pregnancy due date countdown
- Medication schedule tracking
- Fitness challenge duration
- Diet plan day counting
Legal & Finance:
- Contract period calculation
- Statute of limitations tracking
- Payment term verification
- Interest accrual period
- Rental agreement duration
Event Planning:
- Wedding countdown
- Event preparation timeline
- Registration deadline tracking
- Ticket sale period
Quick examples:
- 'How many days until my vacation?'
- 'How long have I been at this job?'
- 'What's my exact age in days?'
- 'How many business days until the deadline?'
Key Features
- Calculate days between two dates
- Breakdown by years, months, and days
- Net working days excluding national public holidays (US, UK, CA, AU)
- Custom holiday dates for company-specific closures
- Business days and weekend days split
- Inclusive or exclusive end-day counting
- Total weeks, hours, minutes, and seconds
- Quick 'Today' button for both dates
- Accurate leap year handling
- DST-safe whole-day counting
- Month-end clamping (EDATE convention)
- Visual calendar timeline
- Shareable result URL
- 100% client-side processing
- No server communication
- Dark mode support
- Mobile-friendly interface
