Skip to content
KJPOkjpo

Add / Subtract Date

Add or subtract years, months, weeks and days from a date and see the resulting date and weekday.

Add / Subtract Date

Add or subtract years, months, weeks and days from a date.

Operation

Date after adding

Thursday, 29 February 2024

  • ISO date: 2024-02-29

If the target month is shorter, the day clamps to its last day: Jan 31 + 1 month = Feb 28 (29 in a leap year).

How it works

Enter a start date and how much to add or subtract. Years and months are applied first, then weeks and days as exact day counts.

  • If the target month is shorter, the day clamps to its last day: Jan 31 + 1 month = Feb 28 (29 in a leap year).
  • Weeks and days are exact counts and never clamp.

Method

date₁ = start date + (years × 12 + months) months, day clamped to the month's last day

result = date₁ + (weeks × 7 + days) days

Worked example: 2024-01-31 (Wednesday) + 1 month = 2024-02-29 (Thursday).

More examples and edge cases

  • 2024-02-29 (Thursday) + 1 year = 2025-02-28 (Friday) — the day clamps because 2025 has no Feb 29
  • 2024-03-31 (Sunday) − 1 month = 2024-02-29 (Thursday)
  • 2024-03-31 (Sunday) − 90 days = 2024-01-01 (Monday)
  • 2024-01-15 (Monday) + 6 weeks = 2024-02-26 (Monday)

More date & time tools