Enter the starting and ending dates into the calculator to determine the total number of days between two dates. You can also use the other tabs to find your next anniversary or a milestone day.
Related Calculators
- Marriage Date Calculator
- Age In Days Calculator
- Lunar Calendar Calculator
- 12 Hours From Now Calculator
- All Everyday Life and Education Calculators
Relationship Date Formula
The following formula is used to calculate the exact number of days between two dates (using real month lengths and leap years).
D = \frac{t_2 - t_1}{86{,}400}Variables:
- D is the total number of days between the start date and end date (end date minus start date)
- t1 is the time (in seconds) at 00:00 (midnight) on the start date
- t2 is the time (in seconds) at 00:00 (midnight) on the end date
- 86,400 is the number of seconds in one day
To calculate the number of days between two dates, convert each date to a consistent “midnight” time value, subtract the start date from the end date, and then divide by 86,400 to convert seconds to days. This approach automatically accounts for different month lengths and leap years.
How to Calculate Relationship Date?
The following steps outline how to calculate the number of days between two dates using the given formula:
- First, determine the start date.
- Next, determine the end date.
- Convert the start date to a midnight time value (t1).
- Convert the end date to a midnight time value (t2).
- Subtract to find the time difference: t2 − t1.
- Divide by 86,400 to convert seconds to days.
- The result is D, the total number of days between the two dates.
- After calculating, check your answer with the calculator above.
Example Problem:
Use the following values as an example problem to test your knowledge:
Start date = 2020-06-15
End date = 2022-09-25
Total days between dates (D) = 832 days
(This is the calendar-accurate difference between 2020-06-15 and 2022-09-25, accounting for real month lengths and leap years.)
Verify the result using the calculator above.
