🔧 Operation
📅 Birth date
📅 As-of date (default: today UTC)
The as-of date defaults to today (local) on page load. Calculations themselves use UTC, so adjusting one date or the other never produces timezone drift in the result.
📅 From date
📅 To date
The "To" date must be on or after the "From" date. Use the Compute Age operation if you want a default as-of-today comparison.
📤 Result
🎂 Age breakdown
- Birth date
- {{ computeResult.birth.isoDate }}
- As of
- {{ computeResult.asOf.isoDate }}
- Calendar age
- {{ computeResult.years }} y {{ computeResult.months }} m {{ computeResult.days }} d
- Total months
- {{ computeResult.totalMonths.toLocaleString() }}
- Total weeks
- {{ computeResult.totalWeeks.toLocaleString() }}
- Total days
- {{ computeResult.totalDays.toLocaleString() }}
- Total hours
- {{ computeResult.totalHours.toLocaleString() }}
- Total minutes
- {{ computeResult.totalMinutes.toLocaleString() }}
- Total seconds
- {{ computeResult.totalSeconds.toLocaleString() }}
- Born on
- {{ computeResult.bornOnDayOfWeek }}
- Western zodiac
- {{ computeResult.zodiacWestern }}
- Chinese zodiac
- {{ computeResult.zodiacChinese }}
📏 Years between
- From
- {{ betweenResult.from.isoDate }}
- To
- {{ betweenResult.to.isoDate }}
- Calendar difference
- {{ betweenResult.years }} y {{ betweenResult.months }} m {{ betweenResult.days }} d
- Total days
- {{ betweenResult.totalDays.toLocaleString() }}
ℹ️ About Age Calculator
What this tool does
The Age Calculator computes calendar age: the completed years, completed months, and remaining days between a birth date and an as-of date, plus elapsed totals derived from UTC day counts. It supports two operations:
- Compute age — given a birth date and optional as-of date, return a calendar-aware
{years, months, days}tuple plus totals in months/weeks/days/hours/minutes/seconds, the next-birthday date and weekday, the day of the week the person was born, and decorative Western + Chinese zodiac signs. - Years between — given two dates, return the calendar age difference (years/months/days) and the absolute total days. Useful for relative comparisons like "how much older is X than Y".
Calendar definition
All arithmetic uses the proleptic Gregorian calendar
(modern leap-year rule extended backward in time) and is performed
with Date.UTC internally, so the same input always
produces the same output independent of the user's timezone or
DST rules. Years from -9999 through 9999 are supported. Calendar
dates are validated by round-tripping through setUTCFullYear,
so Feb 30 → Mar 2 auto-rollover is rejected as invalid.
The web form pre-fills the as-of fields with today's local
calendar date for convenience. Once the values are entered,
calculations treat each YYYY-MM-DD as a date-only
value at UTC midnight; the API also defaults a completely omitted
as-of date to today in UTC. This avoids daylight-saving gaps,
repeated local clock hours, and host timezone differences changing
a birthday, anniversary, or total-day result.
What the output covers
- Years / months / days — conventional calendar breakdown. Borrowing across month boundaries uses the calendar length of the borrowed month, so Feb-29 birthdays in non-leap target years compute against a Feb-28 anchor as appropriate.
- Total months — completed full months between the two dates.
- Total days / weeks / hours / minutes / seconds — exact elapsed time. The day count uses UTC midnights, and hour/minute/second totals scale linearly from days.
- Next birthday — the next anniversary of the birth date strictly after the as-of date. For Feb 29 birthdays, non-leap target years fall back to Feb 28.
- Day of week born — proleptic Gregorian weekday lookup.
- Zodiac signs — decorative only; see notes below.
Use cases
- HR and compliance — verifying minimum-age eligibility, calculating service tenure, or computing retirement-age windows.
- Life-event planning — finding the next milestone birthday, planning anniversaries, scheduling annual reviews.
- Demographic research — converting birth-date columns to age-as-of-snapshot for statistical analysis without local-timezone drift.
- "Days alive" curiosities — calculating elapsed seconds, minutes, hours since birth for personal milestones (your billionth second, your ten-thousandth day, etc).
- Relationship math — using Years between to compute exact age differences between siblings, partners, historical figures, etc.
Zodiac notes (decorative, not astrological)
The Western zodiac field uses the standard 12 tropical signs (Aries through Pisces) with conventional date ranges. Boundaries follow the common Western newspaper-astrology convention — Gemini covers May 21 through June 20, Cancer starts June 21, and so on. These dates are fixed and do not track the actual equinox/solstice shift the way scientific tropical astrology does.
The Chinese zodiac field uses a simple Gregorian-year mapping to the 12-animal cycle (Rat, Ox, Tiger, Rabbit, Dragon, Snake, Horse, Goat, Monkey, Rooster, Dog, Pig). The actual Chinese (lunisolar) new year falls between late January and mid-February, so people born in January or early February of a given year may belong to the previous animal under the traditional lunar calendar. We use the Gregorian-year mapping here for predictability — for the precise lunar boundary, consult the tables at Helmer Aslaksen's Mathematics of the Chinese Calendar (linked under References).
Neither field is intended for astrological forecasting; both are cultural/decorative labels included for fun.
Worked example
Birth date 1990-06-12, as-of date 2026-05-26:
- Calendar age: 35 years, 11 months, 14 days.
- Total days alive: 13,132.
- Total seconds alive: 1,134,604,800.
- Next birthday: 2026-06-12 (Friday), 17 days away.
- Born on a Tuesday.
- Western zodiac: Gemini (Cancer starts June 21).
- Chinese zodiac: Horse (1990 was the Year of the Yang Metal Horse).
In Years between mode, 2000-01-01 to 2026-01-01 returns 26 years, 0 months, 0 days and 9,497 total days. That illustrates the difference between a calendar interval and a raw average-year estimate: leap years are counted by the calendar, not by dividing by 365.25.
Privacy note
The interactive page runs the age calculation in your browser and does not need to upload birth dates for normal use. The public API endpoint accepts the same fields for automation, so avoid sending real personal birth dates to the API unless you are comfortable with normal server request handling for that environment.
References
- ISO 8601 date and time format — standardized date representation, including the year-month-day order used by
YYYY-MM-DD. - ECMAScript Date.UTC and UTC date methods — the JavaScript date primitives used for timezone-independent day counts.
- IANA Time Zone Database — background on why civil time, UTC offsets, and daylight-saving rules are kept separate from date-only calculations.
- Reingold & Dershowitz, Calendrical Calculations, 3rd ed., §2.6 — Gregorian leap-year rule and proleptic conventions.
- Helmer Aslaksen, The Mathematics of the Chinese Calendar, math.nus.edu.sg/aslaksen/calendar/chinese.shtml — full lunar-new-year tables and zodiac mapping.
- For weekday lookup details and ISO week numbering, see the Day of Week Calculator.
- For leap-year edge cases (Feb 29 handling), see the Leap Year Checker.
API Usage Example:
POST /api/tools/time/age-calculator
Content-Type: application/json
{
"operation": "compute",
"birthYear": 1990,
"birthMonth": 6,
"birthDay": 12
}