Years, Months, Days Between two dates in Excel

Add to Favorites
Author: N/A

I have found a rather convoluted method to Calculate the Number of Years, Months and Days between to Dates in Excel. First you will need to calculate the number of Days between the two Dates. Use the following Formaula.


Where B3 is the Statrting Date and G3 is the End Date

then use the following formula for the number of YEARS


Where H3 is the Number of Days resulting from the previous calculation

Use the following formula for the Number of MONTHS

=ROUNDDOWN((H3 - (I3*360))/30,0)

With I3 being the previously calculated number of years

Use the following formula for the Number of Days

=H3-(I3*360) -(J3*30)

With J3 being the previously calculated months.

Don't worry that the system is based on a 360 day year and 12 equal months of 30 days, this is what makes it work without rounding errors.

I have also found a method of calculating Years, Months, Days Using The Now function to retrieve the number of days between two dates with one of the dates being the current date eg


Whereas B3 still represents the Beginning date. But since the number of days returned is the Exact number of days since the beginning and is based on 365+Days per year with uneven months there are generally some rounding errors. Years and Months seem to come out ok but days can be off, I haven't noticed more than a 1 day difference but it could be more pronounced closer to February. I will paste those formulas below first year then month then days

=ROUNDDOWN(C3/365.24218967, 0)       

Where C3 is the location of the aforementioned NOW formula


Where D3 is the calulation of the above year formula

=ROUNDDOWN(C3-(365.24218967*D3) - (E3*30.41666667),0)

Where E3 is the month Formula

Question? Ask it in our Excel Forum

Excel Function: DAYS360(), NOW(), ROUNDDOWN()

Similar Content on TeachExcel
Get the Number of Workdays Between Two Dates in Excel
Tutorial: How to calculate the total number of working days between two dates in Excel.  This allow...
Calculate the Difference Between Two Times in Excel
Tutorial: Here, youll learn how to get the difference between two times in Excel. A common example...
How to Use Dates in Excel
Tutorial: Introduction Guide to using Dates in Excel - this tutorial will show you how to input and...
Dates in Excel Explained
Tutorial: I'll explain how dates in Excel work and then point you to many useful tutorials on how t...
Calculate the Difference Between Time Greater than 24 Hours in Excel
Tutorial: Ill show you how to calculate the difference between two times in Excel when that differe...
Increment a Date By X Days for Each Row in Excel
Tutorial: How to quickly increment a date by a certain number of days for each entry. Type the first...