Skip to content
Verify InstituteA little more certainty.No account required
Methods and assumptions documented

Add or Subtract Days Calculator

Move forward or backward by whole calendar days or weeks. See an unambiguous result date and weekday, with leap years handled explicitly.

Your starting date & offset

See the method ↓

Choose dates using the native date picker. Results use YYYY-MM-DD. Gregorian calendar dates from year 0001 to 9999 are supported; no clock time or time zone is assumed.

Loading calculator… If this message remains, reload the page.

Calendar convention

One week means 7 calendar days, including weekends and holidays. Changing the unit clears the offset. Zero returns the same date. No inclusive extra day is added.

Calculations run on your device. Input values are not placed in the URL or sent to analytics.

HOW THE CALCULATION WORKS

Shift a Gregorian date by a whole number of calendar days

  1. Days before year Y = 365 × (Y−1) + floor((Y−1)/4) − floor((Y−1)/100) + floor((Y−1)/400). Add earlier month lengths and the day of month; 0001-01-01 has ordinal (numbered calendar day) 1. Here floor means round down to a whole number. Weekday index = the remainder after dividing (ordinal−1) by 7, starting with Monday at index 0.
  2. Day shift = offset × 1 for days or offset × 7 for weeks, with a negative sign for subtract. Target ordinal = start ordinal + day shift.
  3. Recover the target year by bounded search, then subtract month lengths to find the month and day. Keep the result within 0001-01-01 through 9999-12-31.
  4. No inclusive extra day is added. An offset of zero returns the starting date.

Worked example

Start 2024-02-28 and add 2 days: result 2024-03-01, a Friday. Subtracting 2 days from 2024-03-01 returns 2024-02-28. Adding 1 week is the same as adding 7 calendar days.

Defaults and assumptions

Limitations

Precision and rounding

All calculations use exact bounded integers. Date ordinals (numbered calendar days) run from 1 to 3,652,059; the largest elapsed gap is 3,652,058 days. No rounding, milliseconds, timestamp conversion or local-time parsing enters the calculation. The review record creation timestamp is metadata only.

Sources

Use the assumptions, worked example and sources to interpret your result. Estimates do not replace professional advice.

How to use this calculator

  1. Choose a starting date, then select add or subtract.
  2. Enter a nonnegative whole-number offset and select days or weeks. Changing the unit clears the offset; enter the quantity for the new unit.
  3. Calculate the result date and weekday. Inspect the signed calendar-day shift and the documented limits.

Common questions

Is the start date day one?

This is an offset, not an inclusive count. Adding zero returns the same date; adding one returns the following calendar date.

Can I enter a negative number to subtract?

Choose subtract and enter a nonnegative magnitude. The tool rejects negative offsets to avoid an ambiguous double negative.

Are weekends and holidays skipped?

No. Every calendar day counts, including weekends, holidays and leap days. A week always means seven calendar days.

Why did the offset clear when I changed units?

Two days and two weeks mean different shifts. Clearing the quantity asks you to enter the intended value instead of silently changing its meaning.

Report a problem or suggest a calculator

Found a confusing result, a missing option, or an idea for a new calculator? Send it privately to the site owner.

Opening the form loads Cloudflare Turnstile, a spam check that processes connection and device information. Privacy details.

Related tools