Everyday
Date Difference Calculator
Calculate the exact number of days between any two dates. See the result in total days, weeks, and a breakdown by years, months, and days.
Total Days Apart
0days
Weeks
0 wk
Years
0
Months (remainder)
0
Days (remainder)
0
Broken down: 0 days
Advertisement
Date Difference Formula
Total Days
Days = (End Date − Start Date) ÷ 86,400,000 ms
Leap years are handled automatically. All results are based on UTC midnight timestamps.
Common Uses
Project timelines — find how many days remain until a deadline or how many days a project ran.
Age calculation — for a precise age in years, months, and days use our Age Calculator.
Contracts and invoices — verify payment terms (e.g. Net 30) by finding the exact due date from an invoice date.
Frequently asked questions
How do you calculate the number of days between two dates?
Subtract the earlier date from the later date in milliseconds, then divide by 86,400,000 (ms per day). Most programming languages and spreadsheets offer a built-in date-difference function. This calculator handles all the edge cases including leap years.
Does the date difference include both the start and end date?
This calculator counts the number of complete days between the two dates — the start date is day 0 and the end date adds its full day. If you want to include both endpoints (e.g. counting total event days), add 1 to the result.
How many days are there in a year for date calculations?
A regular year has 365 days; a leap year has 366. Leap years occur every 4 years (divisible by 4), except century years (divisible by 100) unless they are also divisible by 400. The calculator accounts for leap years automatically.
Can I calculate dates across different years?
Yes. The date difference calculator works across any range of dates, including multi-year spans. It shows the breakdown in total days, weeks, and also as a years + months + days decomposition.
How is the year-month-day breakdown calculated?
The calculator computes full years elapsed, then remaining full months, then remaining days — similar to how age is calculated. This gives an intuitive breakdown (e.g. 1 year, 3 months, 5 days) rather than just a raw day count.