Date Calculator
How many days between two dates?
Find the exact number of days between any two dates, or calculate what date it will be after adding or subtracting a specific number of days.
—
Send feedback
💡 Share your idea or report a problem
✓ Thanks! We'll take a look.
Learn more
How It Works
The formula, explained simply
Date calculations work by converting dates into milliseconds since January 1, 1970, then finding the difference. What seems like simple arithmetic actually involves complex calendar rules that most people never consider.
Leap years add an extra day every four years, except for years divisible by 100 unless they're also divisible by 400. This means 2000 was a leap year but 1900 wasn't. The calculator handles these exceptions automatically, but understanding them helps explain why some year calculations might seem off by a day.
Business day calculations involve iterating through each date and checking whether it falls on a weekend. This is why business day calculations take slightly longer than simple calendar day math, especially for longer date ranges.
When To Use This
Right tool, right situation
Use this calculator when exact day counts matter for contracts, project management, or legal deadlines. It's particularly valuable for business planning where you need to know working days versus calendar days.
Avoid using it for historical dates before 1582 in Catholic countries or 1752 in England, when the Gregorian calendar replaced the Julian calendar. The calculator assumes modern Gregorian rules for all dates.
For financial calculations involving interest or payments, remember that many systems use 30/360 day count conventions rather than actual calendar days. This calculator shows actual days, which may differ from financial system calculations.
Common Mistakes
Why results sometimes look wrong
The biggest mistake is assuming all months have the same number of days when doing mental math. People often estimate 30 days per month, but the actual range of 28-31 days creates significant errors over multiple months.
Another common error is forgetting that business day calculations depend on which day of the week you start. Adding 5 business days to a Wednesday lands you on the following Wednesday, but adding 5 business days to a Friday pushes the result into the next week.
Many people also miscalculate age in days by forgetting leap years. Over a 30-year period, leap years add about 7-8 extra days that casual calculations miss completely.
The Math
Worked examples and deeper derivation
The core math converts dates to Unix timestamps (milliseconds since January 1, 1970) then divides by 86,400,000 milliseconds per day. This handles timezone-independent calculations and automatically accounts for daylight saving time transitions.
For business days, the calculator steps through each date individually, checking if the day of week (0=Sunday, 6=Saturday) falls between 1-5. This iteration method ensures accuracy across months with different weekend patterns.
Week calculations divide total days by 7, while partial weeks show as decimals. The math assumes all weeks contain exactly 7 days, which works for most planning purposes but may need adjustment for specific business contexts.
Expert Unlock
The thing most explanations skip
Professional project managers often use business day calculations to set realistic deadlines that account for team availability. A 20-business-day project actually takes 28 calendar days when you include weekends, which affects resource planning and client expectations.
How accurate are date calculations across leap years?
Need something this doesn't cover?
Suggest a tool — we'll build it →