To calculate your exact age, subtract your birth date from today and handle the day and month carries. Most people use the rough formula "current year minus birth year", but that is only right for about half the year (after your birthday). The exact age in years, months, and days requires a full date subtraction.
The simple formula (year only)
Age in years = current year - birth year - (1 if birthday has not occurred this year, else 0).
Example: born June 15, 1990. Today is May 23, 2026. June 15 has not happened yet in 2026, so age = 2026 - 1990 - 1 = 35. On June 15, 2026, age becomes 36.
This works for filling out forms ("age 35") but loses the months and days.
The exact formula (years, months, days)
Step 1: Subtract birth day from today's day.
Step 2: If the result is negative, add the number of days in the previous month, then subtract 1 from the month count.
Step 3: Subtract birth month from today's month (after any adjustment from step 2).
Step 4: If the result is negative, add 12 to the months and subtract 1 from the year count.
Step 5: Subtract birth year from today's year (after any adjustment from step 4).
Result: years, months, days.
Worked example
Birth date: June 15, 1990. Today: May 23, 2026.
- Today's day (23) - birth day (15) = 8 days. Positive, no carry needed.
- Today's month (5) - birth month (6) = -1. Negative. Add 12 and subtract 1 from years: months = 11, year carry = -1.
- Today's year (2026) - birth year (1990) - 1 (carry) = 35.
- Result: 35 years, 11 months, 8 days.
Sanity check: 35 years 11 months 8 days from June 15, 1990 lands on May 23, 2026. Correct.
The Excel/Google Sheets way
Use the DATEDIF function. The syntax DATEDIF(start_date, end_date, unit) returns the difference in the specified unit:
=DATEDIF(A1, TODAY(), "y")returns whole years.=DATEDIF(A1, TODAY(), "ym")returns leftover months after the whole years.=DATEDIF(A1, TODAY(), "md")returns leftover days after the whole years and months.
Combine in one cell: =DATEDIF(A1,TODAY(),"y")&" years, "&DATEDIF(A1,TODAY(),"ym")&" months, "&DATEDIF(A1,TODAY(),"md")&" days" produces "35 years, 11 months, 8 days".
Age in days, hours, minutes, seconds
Subtract the two dates in milliseconds (JavaScript) or days (Excel) and convert.
- Days: (today - birth date) divided by milliseconds in a day (86,400,000).
- Hours: days × 24.
- Minutes: hours × 60.
- Seconds: minutes × 60.
So a 35-year-old has lived about 12,783 days, or 306,800 hours, or 18.4 million minutes, or 1.1 billion seconds. These are fun figures but rarely useful for official purposes.
Common edge cases
February 29 birthdays. Born on Feb 29? In non-leap years, the convention is to celebrate either Feb 28 or Mar 1, depending on culture and personal preference. Most calculators (including ours) treat Feb 28 as the anniversary date for legal age in non-leap years.
Born across time zones. A baby born at 11pm Pacific time on January 1 is technically born on January 2 in Eastern time. Birth certificates use the local time of birth. Age calculators using your computer's local time may show a date one off if your timezone differs from your birth timezone.
Daylight saving time. The shift from standard to daylight saving (or back) can briefly shift the day boundary near midnight. This rarely affects calculated age because the calculation rounds to whole days.
How software handles it
JavaScript's built-in Date object handles all the leap year, month length, and time zone arithmetic correctly. Our age calculator uses the Date object. The same calculation in Excel uses DATEDIF, which is identical in approach. Python uses the datetime module with similar logic. Most age calculators across languages converge on the same answer because they all rely on the same underlying date arithmetic.
The 1 percent of cases where calculators disagree: leap-year Feb 29 birthdays in non-leap years, and edge cases right around midnight in different time zones. For all other dates, every reasonable calculator gives the same year-month-day breakdown.
Use our age calculator
Type your birth date into our age calculator and see your age in years/months/days, total days, total weeks, total hours, total minutes, total seconds, plus when your next birthday is. The calculator runs in your browser, so no data is uploaded. It handles all the edge cases correctly.