Tenure refers to the service period of an employee. Employers often need to keep track of the tenure of their employees for various reasons. Excel can help in this matter. In this article, we will learn 5 different approaches how to calculate tenure in years and months in Excel.
Download Practice Workbook
Download this practice workbook for practice while you are reading this article.
5 Easy Methods to Calculate Tenure in Years and Months in Excel
In this article, we will learn 5 easy methods to calculate tenure in years and months in Excel. We will use the following dataset to demonstrate these methods. In the following dataset, we have shown the Joining Date and Leaving Date of some employees. Now we will calculate their tenure.
1. Apply DATEDIF Function to Calculate Tenure in Years and Months
This is the most convenient method to calculate tenure in years and months in Excel. We will use the DATEDIF function for this purpose. Follow the steps to calculate tenure using the DATEDIF function.
Steps:
- First, select the empty cell E5.
- Then write down the following formula.
=DATEDIF(C5,D5,"y") & " Years " &DATEDIF(C5,D5,"ym") & " Months "
- Here, C5 refers to the joining date and D5 refers to the leaving date.
- Next, Press Enter. You will see the desired result in cell E5.
- Then drag the bottom right corner of cell E5 to E12 by holding the left button of the mouse.
- Thus you will get the values of years and months for all the dates.
Read More: How to Calculate Average Tenure of Employees in Excel
2. Insert LET Function
Now you will see another approach to calculate tenure in years and months format. We will use the LET function in the following procedure.
Steps:
- First of all, click on cell E5.
- Now type the following formula in the cell.
=LET(start,C5,end,D5,DATEDIF(start,end,"y")&" Years "&DATEDIF(start,end,"ym")&" Months")
- In the formula, C5 and D5 refer to the joining and leaving dates respectively.
● LET(start,C5,end,D5, assigns the name start for cell C5 and end for cell D5.
● DATEDIF(start,end,”y”)&” Years “&DATEDIF(start,end,”ym”)&” Months”) looks into the start date and end date and returns tenure value in years and months.
- Hit Enter to see the result in cell E5.
- Now, if you want to see the results for all the data, just double-click the bottom right corner of cell E5.
- It will show the results in years and months format.
Read More: How to Apply Excel Formula to Count Days from Date to Today
3. Combine INT and ROUND Functions to Calculate Tenure
In this procedure, we will demonstrate the calculation of tenure by combining two functions (INT & ROUND). Keep on reading to learn the steps.
Steps:
- To begin with, move your cursor to the cell E5 and click on it.
- Then write down the formula given below:
=INT((D5-C5)/365.25)&" Years "& ROUND((((D5-C5)/365.25)- INT((D5-C5)/365.25))*12,0)&" Months"
● INT((D5-C5)/365.25 subtracts the date from cell D5 to C5. Then divides the value by 365.25 and returns years in integer format. In cell E5, it returns 17 Years.
● ROUND((((D5-C5)/365.25)- INT((D5-C5)/365.25))*12,0) multiplies the fraction part of the year and round it off to return the value of months. In cell E5, it returns 5 Months.
- To get the result, press Enter.
- Then double-click the bottom right corner of E5 cell and see the results for all the dates.
Read More: Excel Formula to Calculate Number of Days Between Today and Another Date
Similar Readings
- How to Calculate Age on a Specific Date with Formula in Excel
- How to Minus Number of Days or a Date from Today in Excel
- Add Years to a Date in Excel (3 Easy Ways)
- How to Add Days to a Date in Excel Excluding Weekends (4 Ways)
- How to Calculate Expiration Date with Excel Formula
4. Use DAYS Function
Now you will learn how to calculate tenure in years and months in Excel using the DAYS function.
Steps:
- First, select the cell (E5) where you want to show the result.
- Next, type the following formula in the cell.
=INT(DAYS(D5,C5)/365.25)&" Years "& ROUND(((DAYS(D5,C5)/365.25)- INT(DAYS(D5,C5)/365.25))*12,0)&" Months"
● INT(DAYS(D5,C5)/365.25) divides the number of days by 365.25 and returns the results in integer format.
● ROUND(((DAYS(D5,C5)/365.25)-INT(DAYS(D5,C5)/365.25))*12,0) multiplies the fraction part of the year and round it off to return the value of months.
- To get the tenure years and months, hit the Enter button on your keyboard.
- Then you can get the results for all the data by moving the cursor at the bottom right corner and clicking the left-button of the mouse twice.
Read More: Excel Formula to Find Date or Days for Next Month (6 Quick Ways)
5. Utilize YEARFRAC Function
In this method, we will use the YEARFRAC function for tenure calculation. Let us describe the process below:
Steps:
- First of all, go to cell E5 and select it.
- Then write down the formula below in that cell.
=INT(YEARFRAC(C5,D5))&" Years "& ROUND((YEARFRAC(C5,D5)- INT(YEARFRAC(C5,D5)))*12,0)&" Months"
● INT(YEARFRAC(C5,D5)) returns the number of years between the date of C5 and D5 in integer format.
● ROUND((YEARFRAC(C5,D5)-INT(YEARFRAC(C5,D5)))*12,0) multiplies the fraction part of the year and round it off to return the value of months.
- Now press Enter Years and months of tenure will be shown in the cell E5.
- To calculate tenure for all the employees, click the bottom right corner of cell E5 two times.
Read More: How to Calculate Years Between Two Dates in Excel (2 Methods)
Things to Remember
- While using a formula, don’t forget to give proper cell references or you won’t get the desired results.
- Be careful about using the parenthesis while writing any formula. Parenthesis in the wrong position might show wrong results.
Concluding Remarks
Thanks for making it this far. I hope you find this article useful. Now you know 5 different methods to calculate tenure in years and months in Excel. Please let us know if you have any further queries and feel free to give us any recommendations in the comment section below.
Related Articles
- How to Use COUNTIFS with Date Range in Excel (6 Easy Ways)
- How to Count Months in Excel (5 ways)
- Excel Formula to Count Days from Date (5 Easy Methods)
- How to Add 7 Days to a Date in Excel (3 Methods)
- How to Count Date Occurrences in Excel (3 Suitable Examples)
- How to Add Weeks to a Date in Excel (4 Simple Methods)