Return to Excel Formulas List Number of Years Between Dates in Excel & Google SheetsDownload Example Workbook Download the example workbook This tutorial will demonstrate how to calculate the number of years between two dates in Excel & Google Sheets. DATEDIF FunctionTo calculate the number of years between dates you can use the DATEDIF Function with unit of measurement y for years: 1 =DATEDIF(B3,C3,"y") Next you can use the ym input with the DATEDIF function to return the remaining number of months: 1 =DATEDIF(B3,C3,"ym") and join them together to output the number of years and months between two dates: 1 =DATEDIF(B3,C3,"y")&"Years and"&DATEDIF(B3,C3,"ym")&" Months" YEARFRAC FunctionInstead if you want to determine the number of years, including fractional values you can use the YEARFRAC Function: 1 =YEARFRAC(B3,C3) You can add in the TRUNC or INT Functions to calculate the number of full years (just like the DATEDIF Function): 1 =TRUNC(YEARFRAC(B3,C3)) Or you can use the ROUND Function to round to the nearest year: 1 =ROUND(YEARFRAC(B3,C3),0) Last, you can use the ROUNDUP Function to count any partial year as a full year: 1 =ROUNDUP(YEARFRAC(B3,C3),0) All of the above examples work exactly the same in Google Sheets as in Excel. |