Skip to content
kitto works
All tools

Date Difference Calculator

Work out the days, weeks, months and years between two dates, or find the date that's a set number of days, months, or years before or after a given date. Everything runs in your browser — your dates are never sent anywhere.

Your dates are processed entirely in your browser and are never sent anywhere.

Enter your dates above and select Calculate.

How to use

  1. Choose whether you want the days between two dates, or a date that's shifted by adding or subtracting time.
  2. For the days-between mode, enter a start and end date. For add/subtract, enter a base date, an amount, and a unit.
  3. Select Calculate. The days-between mode also shows the same span converted to weeks, months, and years.

How it works

How the days-between calculation works

The number of days between the start and end date is worked out like this:

  • With "Include the end date" off (the default): end date − start date
  • With it on: end date − start date + 1

If the start date happens to be later than the end date, this tool doesn't show an error — it swaps them automatically and calculates the difference, then lets you know it did so.

Converting to weeks, months and years

Weeks are the day count divided by 7, shown as a quotient and remainder (for example, 152 days becomes 21 weeks and 5 days).

Months and years are worked out the same way an age is calculated from a birth date — not by dividing the day count by 30 or 365, but by walking through the actual calendar (months have 28 to 31 days) to produce a breakdown like "0 years, 4 months, 29 days". Every figure — days, weeks, months and years — is derived from the same underlying span (the one that reflects the "Include the end date" setting), so the numbers never contradict each other.

How add/subtract works

Given a base date, this mode adds or subtracts a number of days, weeks, months, or years.

When adding or subtracting months or years, if the resulting month doesn't have that day, the result is clamped to the last day of that month. For example, one month after 31 January is 28 February (or 29 February in a leap year), never a date that spills into March. In the same way, one year after 29 February in a leap year lands on 28 February the following year if that year isn't a leap year.

Leap years

Leap years (every 4 years, except years divisible by 100 unless they're also divisible by 400) are handled correctly throughout — whether a span crosses 29 February or a calculation is based on that date directly.

Supported date range

This tool works with dates from the year 1 to the year 9999. Dates outside that range, or add/subtract results that fall outside it, produce an error rather than an incorrect answer.

What gets sent anywhere

Nothing. Every calculation happens in your browser, and no date you enter — or any other data — is sent to a server.

FAQ

Does this tool send my dates anywhere?

No. Every calculation happens entirely in your browser, and nothing is sent to a server or external API. This tool doesn't rely on any region-specific data such as holiday lists, so there's no network traffic involved at all.

What's the difference between including and not including the end date?

With it off (the default), the count is "end date minus start date" — so 1 January to 2 January comes out as 1 day. Turning it on counts both the start and end date, so the same range becomes 2 days. Turn it on if your contract or rule counts "starting from today" inclusively.

What happens if I add a month to a date at the end of the month?

If the resulting month doesn't have that day, the result is rounded down to the last day of that month. For example, one month after 31 January is 28 February (or 29 February in a leap year) — it never rolls forward into March.

Are leap years handled correctly?

Yes. The rule for leap years — every 4 years, except centuries not divisible by 400 — is applied correctly, whether you're counting a span that crosses 29 February or shifting a date that starts on 29 February itself.

What if I enter the start and end dates in the wrong order?

It's not treated as an error. The tool automatically swaps them so the earlier date is used as the start, calculates the result, and shows a note that the dates were swapped. You'll get the same answer either way round.