Someone born on March 15, 1990 is 36 years, 7 months, and 27 days old on November 11, 2026. This is the sample on the age LAMBDA page. The 36th birthday is March 15, 2026, and November 11 is after that birthday, so the year count is 36. The month anniversaries then run March 15, April 15, May 15, June 15, July 15, August 15, September 15, and October 15. That is 7 completed months. November 15 has not arrived. October 15 plus 16 days is October 31, and November 11 is 11 days after that. 16 + 11 = 27.
=DATEDIF(DATE(1990,3,15),DATE(2026,11,11),"Y")| A | B | |
|---|---|---|
| 1 | Born | 3/15/1990 |
| 2 | As of | 11/11/2026 |
| 3 | Years | 36 |
| 4 | Months | 7 |
| 5 | Days | 27 |
DATEDIF is the function that returns those three pieces. Excel calculates it and leaves it out of the Insert Function list, so type the name. "Y" is completed years. "YM" is the completed months after those years are removed. "MD" is the completed days after those months are removed.
=DATEDIF(DATE(1990,3,15), DATE(2026,11,11), "Y")
=DATEDIF(DATE(1990,3,15), DATE(2026,11,11), "YM")
=DATEDIF(DATE(1990,3,15), DATE(2026,11,11), "MD")
Those return 36, 7, and 27. "D" returns the whole span in days, 13,390. =DAYS(DATE(2026,11,11), DATE(1990,3,15)) returns the same 13,390. Put the birth date first. An as-of date earlier than the birth date returns #NUM!.
The 15th exists in every month, so this 27 is a count you can check on a calendar. "MD" has long-standing wrong results when the day of the month does not exist in the previous month, especially around the 31st. For a day count you want to audit, use "D".
One name for the three numbers
xl.age.ymd spills years, months, and days across three cells:
=xl.age.ymd(DATE(1990,3,15), DATE(2026,11,11))
The spill is 36, 7, and 27. Save the name from that page the way the LAMBDA how-to describes. The name needs Microsoft 365, Excel 2024, or Excel for the web. Excel 2021 returns #NAME?. The three DATEDIF formulas work without it.
A fraction of a year is a different number
YEARFRAC divides a span by a year and returns one decimal. Start it at the last birthday so the day count stays inside 2026, which has 365 days. March 15 to November 11 is 241 days. You can check that with =DAYS(DATE(2026,11,11), DATE(2026,3,15)). DAYS takes the later date first. YEARFRAC takes the start date first.
=YEARFRAC(DATE(2026,3,15),DATE(2026,11,11),1)| A | B | |
|---|---|---|
| 1 | Birthday | 3/15/2026 |
| 2 | As of | 11/11/2026 |
| 3 | Actual/actual | 0.660274 |
| 4 | 30/360 | 0.655556 |
Basis 1 is actual days divided by the actual length of the year. 241 / 365 = 0.6602739726…, which displays as 0.660274 to six decimal places. The full value is 0.660273973. Completed years plus that fraction:
=DATEDIF(DATE(1990,3,15), DATE(2026,11,11), "Y")+YEARFRAC(DATE(2026,3,15), DATE(2026,11,11), 1)
To nine decimal places, the sum is 36.660273973.
Leave the basis off and Excel uses the US 30/360 count. From the 15th to the 11th is 8 months of 30 days, minus 4 days: 240 − 4 = 236. 236 / 360 = 0.655555…, which displays as 0.655556. Pass 1 when you want 241/365.