How to Calculate Age in Excel

How to Calculate Age in Excel?

September 15th, 2026
1136
10:00 Minutes

Excel is one of the most popular tools used to manage both fundamental and complicated calculations. Calculating age is one of its robust features that seems to be a basic one but is very important for different professionals. It is used by HR professionals tracking employee tenures, data analysts working with demographic datasets, or anyone who wants to stop doing the math manually. It is a great practical skill one should have.

The surprising thing is that Excel does not come with a built-in "AGE" function. It basically offers several powerful date functions that make age calculation accurate, automated, and even dynamic. In this guide, I have explained different methods, from the simplest one-liner to formulas that return exact age in years, months, and days.

Best Different Methods to Calculate Age in Excel

Method Formula Best For
DATEDIF =DATEDIF(C3,TODAY(),"Y") Most accurate completed age in years
YEARFRAC + INT =INT(YEARFRAC(C3,TODAY(),1)) Accurate general-purpose age calculation
Simple Division =INT((TODAY()-C3)/365) Quick age estimates
Years, Months & Days DATEDIF combined formula Exact age breakdown
Specific Date =DATEDIF(C3,DATE(2025,12,31),"Y") Calculating age on a particular date
Specific Year =DATEDIF(C3,DATE(2030,12,31),"Y") Calculating age in a future or historical year
Specific Age Date =DATE(YEAR(C3)+60,MONTH(C3),DAY(C3)) Finding the date someone reaches a specific age

Why Calculate Age in Excel?

Before jumping into the formulas, let's quickly look at where you will need to calculate age in Excel. It helps you to understand the best use of the upcoming methods.

  • HR and Payroll Teams: Calculate employee ages to manage retirement eligibility, benefits, or compliance.
  • Healthcare Databases: Determine patient ages for treatment records or research.
  • School and Education Records: Track student ages for admissions or grade eligibility.
  • Survey and Research Data: Segment respondents by age group for analysis.
  • Personal Use: Maintain family records, subscription renewals, or legal document tracking.

If you regularly work with data in Excel, learning to automate age calculation will save you significant time.

Also Read: COUNTIF Function in Excel

What You Need Before You Start (Prerequisites)?

You can not directly implement a formula to find the age, as the data is stored here in different types. The formula only works on a particular type of data. To calculate age in Excel, you need:

  1. A date of birth value stored in a cell (e.g., cell C3) in a proper Excel date format like DD/MM/YYYY or MM/DD/YYYY.
  2. A reference date, either today's date (using TODAY()) or a fixed date.

Note: Make sure your date values are formatted as actual Excel dates, not text. If formulas return unexpected results or errors, right-click the cell → Format Cells → select "Date" format.

Example of calculating age in excel

Read Also: Excel Keyboard Shortcuts

Method 1: The Basic Age Formula in Excel (Simple Division)

The simplest way to calculate age in Excel is to subtract the date of birth from today's date and divide by 365. It is the best formula for age calculation if you are a beginner to this platform.

=(TODAY()-C3)/365

How it works:

  • TODAY() returns the current date.
  • Subtracting C3 (the birth date) gives the number of days between both dates.
  • Dividing by 365 converts days into approximate years.

Method 1: The Basic Age Formula in Excel ( example1)

The problem: This formula returns a decimal (e.g., 35.38 years). To display only the completed years, wrap it with INT():

=INT((TODAY()-C3)/365)

Method 1: The Basic Age Formula in Excel (example 2)

Drawback: Dividing by a flat 365 does not account for leap years, which can cause minor inaccuracies over time. This method is fine for rough estimates but not recommended for legal or official documentation.

Related Source: Excel Interview Questions and Answers

Method 2: Using YEARFRAC and INT for Greater Accuracy

The YEARFRAC function is designed to return the fraction of a year between two dates. When combined with INT, it gives you a clean, more accurate age in completed years. Its logic is what makes the formula different from the above one.

=INT(YEARFRAC(C3, TODAY(), 1))

Breaking it down:

  • C3, the start date (date of birth)
  • TODAY(), the end date (current date)
  • 1, the basis parameter, which tells Excel to use actual calendar days (actual/actual method)
  • INT(), strips the decimal to return only completed years

Why use basis=1? Without specifying the basis, YEARFRAC defaults to treating every month as 30 days, which is less accurate. Setting it to 1 means Excel uses the real number of days in each month and year, including leap years.

This method is widely considered the best balance between simplicity and accuracy for most use cases.

Method 2: Using YEARFRAC and INT for Greater Accuracy

Also Read: Excel ROUND(): A Quick Guide to Rounding in Excel

Method 3: Using DATEDIF to Calculate Age in Excel (Most Reliable)

The DATEDIF function is particularly built for calculating the interval between two dates. It is one of the most precise options because it counts only fully completed periods.

Basic DATEDIF formula:

  • =DATEDIF(C3, TODAY(), "Y")
  • C3, the birth date
  • TODAY(), the current date
  • "Y", returns the number of complete years elapsed

Important note: DATEDIF is a legacy function in Excel; it works perfectly but does not appear in Excel's autocomplete suggestions. You need to type it manually. Do not let that discourage you; it is one of the most reliable age formulas available.

Method 3: Using DATEDIF to Calculate Age in Excel

Related Source: How to Use Power Query in Excel?

Method 4: Calculate Exact Age in Years, Months, and Days

When you need more than just the year, this formula works best. It combines three DATEDIF calls to get the exact age breakdown. It can be a good choice in the healthcare (medical) industry.

For years:

=DATEDIF(C3, TODAY(), "Y")

Method 4: Calculate Exact Age in Years, Months, and Days ( example 1)

For months (beyond the last completed year):

=DATEDIF(C3, TODAY(), "YM")

Method 4: Calculate Exact Age in Years, Months, and Days ( example 2)

For days (beyond the last completed month):

=DATEDIF(C3, TODAY(), "MD")

Method 4: Calculate Exact Age in Years, Months, and Days ( example 3)

Combined formula in a single cell:

=DATEDIF(C3,TODAY(),"Y")&" Years, "&DATEDIF(C3,TODAY(),"YM")&" Months, "&DATEDIF(C3,TODAY(),"MD")&" Days"

Method 4: Calculate Exact Age in Years, Months, and Days ( example 4 )

Example output: 26 Years, 5 Months, 22 Days

Bonus, hide zero values for cleaner output:

=IF(DATEDIF(C3,TODAY(),"Y")=0,"",DATEDIF(C3,TODAY(),"Y")&" Years, ")&IF(DATEDIF(C3,TODAY(),"YM")=0,"",DATEDIF(C3,TODAY(),"YM")&" Months, ")&IF(DATEDIF(C3,TODAY(),"MD")=0,"",DATEDIF(C3,TODAY(),"MD")&" Days")

This version skips displaying "0 Months" or "0 Days" when they are irrelevant.

Method 4: Calculate Exact Age in Years, Months, and Days ( example 5)

Read Also: How to Create a Dashboard in Excel? A step-by-step Guide

Method 5: Calculate Age on a Specific Date

Sometimes you need to calculate age at a specific historical or future date. For example, a candidate's age on the date of an exam, or an employee's age on a contract start date. This can be your best choice when the age is counted with respect to a predefined date.

Simply replace TODAY() with the DATE() function:

=DATEDIF(C3, DATE(2025, 12, 31), "Y")

Method 5: Calculate Age on a Specific Date (Not Today) example 1

This formula tells you how old the person was (or will be) on December 31, 2025.

For a full breakdown on a specific date:

=DATEDIF(C3,DATE(2025,12,31),"Y")&" Years, "&DATEDIF(C3,DATE(2025,12,31),"YM")&" Months, "&DATEDIF(C3,DATE(2025,12,31),"MD")&" Days"

Method 5: Calculate Age on a Specific Date (Not Today) example 2

This approach is especially useful in HR planning, insurance policy management, or historical data analysis.

Related Source: How to Remove Spaces in Excel?

Method 6: Calculate Age in a Specific Year Only

This formula works when you have a birth year and want to know someone's age in a particular year.

=DATEDIF(C3, DATE(2030, 12, 31), "Y")

Method 6: Calculate Age in a Specific Year Only example 1

For mid-year calculations:

=DATEDIF(C3, DATE(2030, 6, 30), "Y")

Method 6: Calculate Age in a Specific Year Only example 2

This is helpful in long-term workforce planning, pension forecasting, or demographic projections.

Read Also: How to Compare Two Columns in Excel?

Method 7: Find the Date When Someone Reaches a Specific Age

This is one of the most popular and robust age calculation formulas. It helps you to know when a person will be of a particular age. It is used in almost every industry to find out the retirement date of an employee, service date of machines, amd many more. It is also my favorite formula.

=DATE(YEAR(C3)+60, MONTH(C3), DAY(C3))

Method 7: Find the Date When Someone Reaches a Specific Age example 1

This returns the exact future date when the person reaches that age. You can extend this for more complex eligibility checks:

=DATE(YEAR(C3)+30, MONTH(C3)+6, DAY(C3))

Method 7: Find the Date When Someone Reaches a Specific Age example 2

This finds the date when someone will be exactly 30 years and 6 months old.

Related Source: How to Remove Blank Rows in Excel?

Bonus: Highlight Ages Using Conditional Formatting

Once you have age values calculated, you can visually highlight them by age group using Conditional Formatting, useful for quick data review in HR databases or student records.

Steps:

  1. Select your age data range.
  2. Go to Home → Conditional Formatting → New Rule.
  3. Choose "Use a formula to determine which cells to format".
  4. Enter the relevant formula and pick a fill colour.
Group Formula
Under 18 =DATEDIF(C3,TODAY(),"Y")<18
18 to 65 =AND(DATEDIF(C3,TODAY(),"Y")>=18, DATEDIF(C3,TODAY(),"Y")<=65)
Over 65 =DATEDIF(C3,TODAY(),"Y")>65

This visual layer makes large spreadsheets much easier to read at a glance.

Bonus: Highlight Ages Using Conditional Formatting

Quick Comparison: Which Formula Should You Use?

Method Formula Best For Accuracy
Simple Division =INT((TODAY()-C3)/365) Quick estimates Moderate
YEARFRAC + INT =INT(YEARFRAC(C3,TODAY(),1)) General use High
DATEDIF ("Y") =DATEDIF(C3,TODAY(),"Y") Official records Very High
DATEDIF Combined Y + YM + MD combined Medical/Legal Very High
Specific Date =DATEDIF(C3,DATE(…),"Y") Planning/Forecasting Very High

Read Also: Top 120 Excel Multiple Choice Questions (MCQs) For 2026

Common Mistakes to Avoid

Beginners often make multiple mistakes while using a new formula. The following are some of them. It will help you to understand what to avoid.

1. Dates stored as text: If your birth dates are stored as text (left-aligned in the cell), Excel cannot calculate with them. Use the DATEVALUE function or reformat the cells.

2. Dividing by 365 for large datasets: For long timeframes or leap-year-heavy data, this causes cumulative inaccuracies. Switch to DATEDIF or YEARFRAC with basis=1.

3. Forgetting to specify basis in YEARFRAC: Without it, the function defaults to a 30/360 method, not the real calendar. Always include the 1 as the third argument.

4. Not locking reference dates with $: If you use a fixed date in a formula and want to copy it down a column, use an absolute cell reference (e.g., $B$1) instead of typing the date directly in each formula.

5. Expecting DATEDIF in autocomplete: DATEDIF does not appear in Excel's formula suggestions. Just type it manually; it works perfectly.

Wrapping Up

Calculating age in Excel is straightforward once you pick the right formula for your use case. For quick estimates, the basic division formula works. For accuracy in professional settings, DATEDIF or YEARFRAC with basis=1 are the right tools. And for detailed breakdowns in years, months, and days, combining multiple DATEDIF calls gives you everything you need.

Master these formulas, and you will handle any age-related calculation in Excel confidently, whether it is a single birthday or a dataset with thousands of records.

FAQs

Q1. Does Excel have a built-in age function?

No. Excel does not have a dedicated AGE function. However, functions like DATEDIF, YEARFRAC, and INT, when used correctly, give accurate and reliable age results.

Q2. Which is the most accurate formula to calculate age in Excel?

DATEDIF with the "Y" unit is generally the most accurate for calculating completed years, as it accounts for actual calendar differences including leap years and varying month lengths.

Q3. Why is DATEDIF not showing in Excel's autocomplete?

DATEDIF is a legacy compatibility function in Excel. It works perfectly fine but is intentionally hidden from the formula autocomplete list. You must type it manually.

Q4. Can I calculate age in Excel without using TODAY()?

Yes. Replace TODAY() with a specific date using DATE(year, month, day). For example: =DATEDIF(C3, DATE(2025, 1, 1), "Y").

Q5. What happens if the birth date is on February 29 (leap day)?

Both DATEDIF and YEARFRAC handle leap-day birthdays correctly. In non-leap years, Excel treats the birthday as falling on March 1st for calculation purposes.

Q6. How do I calculate age in months or days instead of years?

Use DATEDIF with different unit codes: "M" for total months, "D" for total days, "YM" for months past the last full year, and "MD" for days past the last full month.

About the Author
Sanjay Prajapat
About the Author

Sanjay built his career managing digital campaigns for small and mid-sized businesses, running paid search accounts, optimizing landing pages, and tracking conversion funnels across industries. He tracks search and social algorithm updates by testing changes on live campaigns rather than assuming best practices stay static. His articles give marketers practical tactics to test the same week.

Drop Us a Query
Fields marked * are mandatory
×

Your Shopping Cart


Your shopping cart is empty.