How to calculate years between two dates in Excel

How to calculate years between two dates in Excel

All aspects of life revolve around time. All daily activities we do in our life also depend and revolve on time. We all need to keep track of time because it is a temporary situation. Time is measured or accounted for in seconds, minutes, and hours, days, weeks, months, and years.

To calculate years between years is the general act of getting the number or the value in years between two given dates. We can do that simply by getting the difference between the dates or even by the manual counting of the number of months involved and then translating the months to years.

In excel sheets we also calculate the years that are there in the middle of two dates or even three dates. Unlike the manual counting, excel has these built-in formulas that help in the calculating of the years.

We have some of the steps to follow to reach a value of the years between the given dates. These steps will include the following and are explained below together with the examples.

Step 1

Assuming you have the data set already in the excel sheets you do not have to redo the first step again. For those who are doing it for the first time, open the excel from your laptop, create a new or an empty excel sheet, and record date values of your choice as the case below.

Step 2

To get the years between the dates on the above excel sheets, we are going to use the function YEARFRAC. This is the function that calculates the years between dates. One thing about the YEARFRAC function is that it can calculate even in decimal, for instance, it can display 1.5 years to mean one and a half years.

On the column with the header, years are where we expect to record our results. Enter the following formula in the formula bar =YEARFRAC (A2, B2) to calculate the years between the dates in cell A2 and cell B2.

You can change the cells until you get the years between all those dates in the data set as in the case below.