This page documents every rule our calculators use. Where a question has more than one accepted answer, we explain the option we chose and why. If you think a result is wrong, tell us.
Principles
- Calendar dates, not timestamps. Every calculation works on plain calendar dates (year, month, day). We never subtract millisecond timestamps, so daylight saving changes and time zones can’t shift a result by an hour or a day.
- Your own time zone. “Today” means today’s date on your device.
- One calendar throughout. We use the Gregorian calendar for every date from the year 1 to 9999, including dates before it was introduced in 1582 (the “proleptic” Gregorian calendar). Historical dates recorded in the Julian calendar need converting first.
- Everything runs in your browser. Nothing you type is sent to us.
Age in years, months and days
An age is the time from the date of birth to the target date (today, unless you choose another), counted in whole years, then whole months, then days:
- Find the largest number of whole months, N, such that the date of birth plus N months falls on or before the target date. Years are N ÷ 12 (whole part) and months are the remainder.
- The days are the number of days from that “N-month anniversary” to the target date.
Anniversaries are always measured from the original date of birth, not from the previous anniversary, so 31 January plus two months is 31 March, not 28 March.
When the day doesn’t exist in a month
If the date of birth is on the 29th, 30th or 31st, some months don’t have that day. In that case the anniversary falls on the last day of that month. This is the same rule most calendar software uses when adding months. For someone born on 31 January 2023:
- On 28 February 2023 the age is 1 month.
- On 1 March 2023 it is 1 month and 1 day.
- On 31 March 2023 it is 2 months.
Birthdays on 29 February
For a 29 February date of birth, the same rule makes 28 February the birthday in common years. Because some people, laws and organisations use 1 March instead, the calculators offer that option whenever you enter a 29 February date. With 1 March selected, any anniversary that falls on a missing day moves to the first day of the next month. See our guide to leap day birthdays.
Time of birth
Time of birth doesn’t change the age in years, months and days: you’re a year older from the start of your birthday. It only affects the hours, minutes and seconds.
Days, weeks, hours, minutes and seconds
- Days are the number of calendar days between the dates. The day of birth isn’t counted, so you’re 0 days old on the day you’re born.
- Weeks are days ÷ 7, rounded down. Months are whole calendar months, as above.
- Hours, minutes and seconds count every day as exactly 24 hours (wall-clock time). For today, the time since midnight on your device’s clock is added, and if you gave a time of birth, the time from midnight to your birth is subtracted. For any other target date, the count runs to the start of that day.
- Clock changes for daylight saving are ignored, so totals never jump by an hour.
Next birthday, half birthday and countdowns
- Next birthday is the next anniversary of the date of birth after the target date, or the target date itself if it is the birthday. The days to go are calendar days.
- Half birthday is the date of birth plus the completed years plus six months, using the month-end rule above.
- Progress through the year is the days since the last birthday divided by the days between the last and the next birthday.
- The birthday countdown counts down to midnight at the start of the birthday on your device’s clock.
Date differences and weekdays
The date difference calculator counts from the start date up to the end date, like an age. Ticking “include the end date” adds one day, so a range counts every calendar day from the first to the last. If the end date is before the start date, the dates are swapped. Weekdays are Mondays to Fridays in the counted range. Public holidays aren’t excluded, because they vary by country and region.
Chronological age for testing
The chronological age calculator offers two ways to borrow when the days don’t subtract:
- A calendar month: the method above.
- 30 days: subtract year, month and day separately; if the days are negative, add 30 and take one month; if the months are negative, add 12 and take one year. Many test manuals specify this method.
Rounding, when selected, rounds to the nearest month: 15 or more remaining days round up; fewer round down. Corrected age for a baby born before 40 weeks is counted from the due date, which is the date of birth plus the number of days born early (280 days minus the gestational age in days).
Birth year from an age
Someone who is A years old on date D was born between the day after D minus (A + 1) years and D minus A years, inclusive. Knowing whether their birthday has passed in D’s year narrows this to one calendar year.
Retirement date
The retirement date is the date of birth plus the chosen retirement age in years and months, using the month-end rule. Weekdays remaining are Mondays to Fridays from today up to that date. We don’t know your pension scheme’s rules, so confirm your date with your provider.
Western zodiac
Star signs use the conventional tropical zodiac date ranges, from Aries (21 March to 19 April) to Pisces (19 February to 20 March). The Sun’s actual entry into each sign varies by up to about a day from year to year, so births within a day of a boundary are flagged as being on a cusp.
Chinese zodiac
The Chinese zodiac year starts at Lunar New Year, so we keep a table of Lunar New Year dates for every year from 1899 to 2101. We generated it from the Chinese calendar data built into modern software (ICU), then cross-checked every year against an independent calendar library. The two sources disagreed in three years, 1954, 2027 and 2030, where the new moon falls within minutes of midnight in Beijing; we confirmed the correct dates (3 February 1954, 6 February 2027 and 3 February 2030) with precise astronomical new-moon times. Our tests check the table against published dates.
The animal and element follow the 60-year cycle counted from the lunar year: the animal from the 12-year cycle starting with the Rat, the element from the 10 heavenly stems (two years each of wood, fire, earth, metal and water), and yin or yang alternating each year. For dates outside 1899–2101 we use the calendar year, which can be wrong for births in January or February; the result is marked as approximate.
Generations
Generations follow Pew Research Center’s birth-year ranges: Greatest Generation (1927 and earlier, shown as 1901–1927), Silent Generation (1928–1945), Baby Boomers (1946–1964), Generation X (1965–1980), Millennials (1981–1996) and Generation Z (1997–2012). Generation Alpha (2013–2024) and Generation Beta (2025–2039) have no official definition; we use common ranges and label them as informal. See what generation am I?
Fun facts
The fun facts on the age calculator are rough estimates based on averages, clearly labelled as such:
- Heartbeats: minutes alive × 80. A normal resting heart rate for adults is 60 to 100 beats per minute, and children’s heart rates are higher, so 80 is a middle-of-the-road average.
- Breaths: minutes alive × 16. Adults at rest typically breathe 12 to 20 times a minute.
- Hours asleep: each day of life multiplied by the typical sleep for that age, using the midpoints of the National Sleep Foundation’s recommended ranges (published in Sleep Health, 2015):
| Age | Hours of sleep a day |
|---|---|
| Under 4 months | 15.5 |
| 4–11 months | 13.5 |
| 1–2 years | 12.5 |
| 3–5 years | 11.5 |
| 6–13 years | 10 |
| 14–17 years | 9 |
| 18–64 years | 8 |
| 65 and over | 7.5 |
- Full moons: the number of full moons between the date of birth and the target date, using the mean lunar cycle of 29.530588853 days counted from the full moon of 21 January 2000 at 04:40 UTC. Real full moons drift up to about 14 hours either side of the average, so the count can be off by one.
Pet ages
Dogs. We show two estimates. The DNA-based formula comes from a 2020 University of California San Diego study of DNA methylation in 104 Labrador retrievers: human age = 16 × ln(dog age in years) + 31. We show it from 2 months old, because the curve isn’t meaningful for very young puppies. The size-adjusted rule follows the American Veterinary Medical Association’s guideline (about 15 human years for the first year and 9 for the second), then adds 4, 5, 6 or 7 human years a year for small (up to 9 kg), medium (up to 23 kg), large (up to 45 kg) and giant dogs. Life stages are simplified: puppy under 1, young adult under 3, senior from 7 (small and medium), 6 (large) or 5 (giant) years, and mature adult in between. Read more in dog years to human years.
Cats. We use the widely used conversion chart: 6 months ≈ 10, 1 year ≈ 15, 18 months ≈ 21 and 2 years ≈ 24 human years, interpolated in between, then 4 human years for every cat year after the second. Life stages follow the 2021 AAHA/AAFP Feline Life Stage Guidelines: kitten (under 1), young adult (1–6), mature adult (7–9) and senior (10 and over).
Testing and accuracy
The date logic behind every calculator is covered by an automated test suite of nearly 300 checks, including:
- leap years and century years (1900 was not a leap year; 2000 was),
- 29 February birthdays under both conventions,
- dates of birth on the 29th, 30th and 31st of a month,
- dates of birth in the future (which return a friendly error),
- the day of birth itself, birthdays today and dates years apart,
- time zones and daylight saving changes,
- dates from the year 1 to 9999, checked day by day against an independent calendar,
- thousands of random date pairs checked against the definition above.
Every calculator is also tested in a real browser. If you find a case we’ve missed, please email hello@ageculator.com.