How to datedif age years in Excel
Compute employee tenure, customer age, asset age, or any interval measured in full years.
Step-by-step instructions
How to datedif age years — 3 steps
Put the start date (e.g. birth date or hire date) in column A.
Use TODAY() as the end date so the result updates automatically each day.
Use "Y" as the unit to return the count of complete years.
Example data
Worked example
| Hire Date | Years of Service |
|---|---|
| 2018-03-15 | 7 |
| 2021-11-01 | 4 |
| 2023-06-20 | 2 |
Common mistakes
Errors to watch out for
DATEDIF is undocumented
DATEDIF is intentionally hidden from Excel's function list but still works. Type it manually — Excel will not autocomplete it.
Returns 0 for dates less than a year apart
DATEDIF returns complete units only. If the range is less than 12 months, "Y" returns 0. Use "M" for months or "D" for days if you need finer granularity.
FAQ
Frequently asked questions
How do I also show the remaining months after the full years?
Add a second DATEDIF with the "YM" unit — =DATEDIF(A2,TODAY(),"Y")&" years, "&DATEDIF(A2,TODAY(),"YM")&" months".
Describe your exact spreadsheet problem — get the formula in seconds.
Open AI Formula Generator — FreeRelated how-to guides