Date Difference Calculator (age, duration, ISO weeks)

Pick two moments and a time zone. See the calendar age, the exact duration, ISO weeks and whether daylight saving sits in between.

How it works

Enter a from and optional to (defaults to now) as YYYY-MM-DD, YYYY-MM-DDTHH:MM, a Unix timestamp, or the word now. Choose an IANA time zone so wall-clock midnights and DST rules match the place you care about. Everything runs in your browser; nothing is uploaded.

Age is the birthday-style calendar Y/M/D between the two dates (absolute). Breakdown also folds in the time of day and is signed: negative components mean from is after to.

Across a spring-forward, midnight-to-midnight is 23 hours of real time (and 25 hours across a fall-back). When the UTC offset changes anywhere between the two moments, a DST note appears so a naive hour count does not surprise you.

You also get total seconds, an ISO 8601 duration string, calendar day/week counts, and each end's ISO week number. Swap the ends or set To = now with one click.

Need the same maths from a script or CI job? Anvil's free date difference API returns JSON with no key. Sibling tools: the Unix time converter, the time zone meeting planner and the countdown (sleeps, weekdays and weekend days until a date).

Questions

Is my date uploaded?

No. Parsing and maths are pure JavaScript in your browser.

How is age different from breakdown?

Age is the calendar birthday-style Y/M/D (absolute). Breakdown also folds in the time of day and is signed.

Does it handle leap days?

Yes. 29 February to the next 28/29 February lands on whole years; the calendar rules match civil dates.

What does the DST note mean?

In the chosen time zone, the UTC offset changes at least once between the two moments (spring-forward or fall-back). A naive hour count can then disagree with wall-clock maths.

Is there an API?

Yes. Anvil's keyless /v1/date/diff endpoint at api.oddlathe.com does the same maths and returns JSON.

Related tools

Guides