Add or Subtract Dates

MDN Date & Time Tools

Shiftבס״ד

Move a date forward or back by a number of days, weeks, months or years. When a month is too short for the day you started from, the result is clamped to the last day of that month, and the page says so instead of hiding it.

Add or subtract from a date

—

Weekday
—
Days from the start date
—
What was added or subtracted
—

Days and weeks are exact day counts. Months and years follow the calendar: 31 January plus one month is 28 February in a common year, and 29 February plus one year is 28 February.

Calendar months are not fixed lengths

Adding thirty days and adding one month are different operations, and both are useful. Thirty days after 15 January is 14 February. One month after 15 January is 15 February, which is thirty-one days later. The tool keeps the distinction instead of treating a month as a number of days.

The awkward case is a day that does not exist in the target month. One month after 31 January cannot be 31 February, so the result becomes the last valid day, 28 February, or 29 February in a leap year. The page reports the clamp every time it happens. The same rule applies to 31 March minus one month, which lands on 28 February.

No daylight saving surprises

All arithmetic here is date-only. Because no clock time is involved, adding one day always moves the calendar by one day, even across the night a region changes its clocks. If you need to add hours to a real moment instead, use the time zone converter, which works with instants and reports the ambiguous and skipped readings that a clock change creates.

Common uses

  • Contract and notice periods, such as ninety days from signature.
  • Return windows and warranty dates counted from a delivery date.
  • Follow-up dates, review cycles and renewal reminders.
  • Working out the date of a future anniversary or a past milestone.

Common questions

Why does 29 February plus one year give 28 February?

Because the following year has no 29 February. The anniversary is kept as close as the calendar allows, and the clamp note explains the adjustment.

Can I add working days?

Not on this page, because working days depend on weekends and excluded dates. Use the business day calculator for that, or count business days between two dates there.