Skip to content
HandfulTools

How to Calculate Age and Days Between Two Dates

Work out an exact age in years, months and days, count the days between two dates, and handle leap years, inclusive counts and working days without an error.

· 6 min read

An exact age is three counts, in this order: the full years since the birth date, then the full months since the last birthday, then the days left over. A span between two dates is a subtraction: later date − earlier date. The two questions look alike but they behave differently, because years and months have different lengths while days do not.

The quickest route here: the Age calculator takes a date of birth and any reference date and returns years, months and days along with the totals; the Date difference calculator counts any span, with a switch for whether the end date is included, and can also add or subtract days from a date. Both run on your device, so birth dates and deadlines stay there.

A worked example, step by step

Someone born on 15 May 1990, on 24 September 2026:

  1. Years. Their last birthday, 15 May 2026, has passed, so they are 36.
  2. Months. From 15 May 2026 to 15 September 2026 is 4 full months.
  3. Days. From 15 September to 24 September is 9 days.

That gives 36 years, 4 months and 9 days. The same span expressed differently: 436 full months, 1,897 weeks and 2 days, or 13,281 days. Their next birthday, 15 May 2027, is 233 days away.

Notice what happens if you take the shortcut and divide: 13,281 ÷ 365 = 36.39, which reads as "36 years", and it only survives because the birthday is months away. Near a birthday the drift from nine leap days is enough to hand you the wrong year.

Reference table: spans that catch people out

Span Answer Why
1 Jan 2024 → 1 Jan 2025 366 days 2024 contained 29 February
1 Jan 2025 → 1 Jan 2026 365 days no 29 February
1 Jan 2026 → 1 Jan 2027 365 days no 29 February
Mon 5 Oct → Fri 9 Oct 2026, end excluded 4 days four nights in a hotel
The same span, end included 5 days five days of leave
1 Jan → 31 Dec 2026, weekdays only 261 before any public holiday

Why adding a month is ambiguous

Days are all the same length, so day arithmetic has one answer. Months are not, so month arithmetic has several, and different software picks different ones.

Take 31 January 2026 + 1 month. February 2026 has 28 days, so there is no 31 February. A spreadsheet or database may give you 28 February (clamp to the end of the month) or 3 March (overflow into the next month). Both are defensible. The consequence is that month arithmetic is not reversible: clamping 31 January to 28 February and then subtracting a month gives 28 January, not the 31st you started from.

This is why the three-step method counts full months from the last birthday rather than adding months to the birth date, and why anything with a legal deadline should be defined in days if you can choose. When you cannot — rent, notice periods, subscriptions — find out which convention the other party uses before you assume.

Leap years and 29 February

Year Leap year? Rule
2024 Yes divisible by 4
2026 No not divisible by 4
1900 No century year, not divisible by 400
2000 Yes century year, divisible by 400
2100 No century year, not divisible by 400

A leap year adds 29 February. In full: a year divisible by 4 is a leap year, except century years, unless they are also divisible by 400.

People born on 29 February have a real birthday only every four years — after 2024 the next ones are 2028, 2032 and 2036. In other years they usually celebrate on 28 February or 1 March, and which of the two counts for a legal threshold such as coming of age is decided by national law, not by arithmetic. A calculator that counts full years handles them correctly either way: someone born on 29 February 2000 is 26 years, 6 months and 26 days old on 24 September 2026.

"Include the end date": the classic off-by-one

By default a date difference does not count the end date. From Monday 5 October to Friday 9 October 2026 is 4 days, which is the right answer for four hotel nights, or for "how many days until Friday". Include the end date and you get 5, which is the right answer for a leave request or an event that runs Monday to Friday, because both the first and the last day are used.

If your total is stubbornly one out in the same direction every time, this setting is nearly always the reason. A useful test: ask whether the last day is consumed (leave, an event, a rental period counted in days) or merely reached (a checkout, a deadline, a countdown).

Working days and public holidays

Working days here means Monday to Friday. Public holidays are not removed automatically, because they differ by country, region and sometimes employer, so subtract them yourself.

Take 1 to 31 December 2026, end date included:

  • Weekdays: 23
  • Christmas Day, 25 December 2026, falls on a Friday: 23 − 1 = 22
  • In the UK, Boxing Day falls on a Saturday that year, so the substitute bank holiday lands on Monday 28 December: 21

Company shutdowns come off the same way. Across the whole of 2026 there are 261 weekdays, which is the ceiling before any holiday is deducted.

Time zones

A date is not a moment. "24 September" starts and ends at different instants around the world, so a deadline expressed as a date needs a time zone attached. At 23:30 on 24 September in UTC−5 it is already 13:30 on 25 September in UTC+9: two people, one instant, two different dates and a one-day difference in every count that follows.

For anything crossing borders, agree on a zone and write it down — "23:59 UTC" leaves nothing to interpret. For durations rather than dates, note that a day crossing a daylight-saving change is 23 or 25 hours long, which matters for hours worked but not for whole-day counts.

Common problems, and what they mean

Your total is one day out. The end-date setting. Decide whether the last day is used or only reached.

An age flips a year too early or too late. The days were divided by 365. Count whole birthdays instead.

The working-day count is too high. Public holidays have not been subtracted; the calculator gives weekdays, not your country's business days.

A date entered in a form came out wrong. 03/04 is 3 April in most of Europe and 4 March in the United States. Check which order a form expects, and prefer the unambiguous 2026-04-03 wherever it is accepted.

Adding months gives a date you did not expect. You have hit the 31 January problem above. Switch to counting days if the deadline matters.

Questions people ask

How many days have I been alive? Subtract your date of birth from today. Someone born on 15 May 1990 had lived 13,281 days on 24 September 2026.

Does the calculator count the birthday itself? Age counts completed years, so you turn 36 on the day, not the day after.

What is the date 90 days from today? From 24 September 2026, 90 days later is 23 December 2026. The Date difference calculator adds and subtracts days for any starting date.

Why do two tools give different month counts? They resolve the 31-day problem differently. Compare the day counts instead — those always agree.

Can I count hours rather than days? Yes, with the Time difference calculator, which is the one to use for shifts and timesheets.

Next steps

Tools used in this guide

← All guides