Calculator Hub

Date Difference Calculator

Calculate the number of days, weeks, months, and years between any two dates.

Days2,309
Weeks329.86
Months (avg)75.86
Years (avg)6.322

How it works

This calculator computes the difference between any two calendar dates in several units: days, weeks, average months, and average years. Days are exact — counted by simple subtraction at the day boundary. Weeks divide days by 7. Months and years use averages (30.4375 days per month, 365.25 days per year) because actual months and years vary in length.

For exact month/year counts (like determining a payroll period or a contract anniversary), use the calendar-based age formula instead — the day of the month determines whether the period is "complete". This calculator uses average values, which is fine for general "how long ago" questions but not for legal or financial periods that depend on specific calendar boundaries.

Common uses: figuring out how many days until a deadline, how long since an event, how old something is, how long a project has been running. Date arithmetic in spreadsheets uses the same approach: subtract one date cell from another to get a number of days; divide by 7 for weeks, ~30 for months, ~365 for years.

Watch out for time-zone issues. If you enter "2024-01-01" the system interprets it as midnight in your local time zone. Cross-zone calculations can drift by ±1 day depending on where the two endpoints are evaluated. For business-critical date arithmetic, store dates as UTC or as ISO-8601 with explicit zone, and do the math in a single consistent zone.

This calculator handles dates from year 100 to year 9999 (the JavaScript Date range). For historical calculations (e.g., "how many days from the founding of Rome to today") you may need a Julian-calendar-aware library — the Gregorian calendar wasn't adopted everywhere until the 1700s, and skipping the Julian-Gregorian transition produces wrong day counts.

Frequently asked questions

Why are "average months" not exact?

Months range from 28 to 31 days. Using 30.4375 (≈365.25/12) is an average; for exact counts use specific calendar boundaries.

Does it count both endpoints?

No — the difference is end minus start. Both same day = 0 days. Inclusive counts add 1.