Date Add / Subtract Calculator
Shift a date by years, months, weeks, days, hours or minutes — end-of-month clamping stated, never guessed — entirely on this device.
2026-02-28- Weekday
- Saturday
- Day count
- 28 days from start
- 2026-01-31 + 1 month lands on a 28-day February — day clamped to 2026-02-28.
- Start
2026-01-31 - Years
0 → 2026-01-31 - Months
+1 → 2026-02-28 - Days (weeks fold in as ×7)
0 → 2026-02-28 - Clock time (minutes)
0 → 2026-02-28
Press ? for shortcuts
Do it offline:$ date -d "2026-08-07 +30 days"
How to use it
- Type or pick the start date — Today fills it too; add an optional start time when clock math matters.
- Set the direction on the Add | Subtract toggle — amount fields stay non-negative, the toggle carries the sign.
- Enter whole-number amounts in any of the six unit fields, years down to minutes; weeks fold into the day shift.
- Read the result, weekday and day count, check the trace, then copy or share it as a link.
Pick a start date, choose Add or Subtract, and enter any mix of years, months, weeks, days, hours and minutes. The result appears as you type, with its weekday, a signed day count, and a five-row trace of every stage: years, then months, then days, then clock time. When a month runs short — January 31 plus one month — the day clamps and a chip names both dates. The math runs entirely in this tab.
How it works
Amounts apply in a fixed order: years first, then months, then weeks and days folded into a single day shift, then hours and minutes. The order changes answers. From 2024-02-29, a staged +1 year clamps to 2025-02-28 and the month step then lands on Friday 2025-03-28; one combined jump of 13 months from the same start reaches 2025-03-29. The trace prints each stage, and this page always computes the staged rule.
When a year or month step lands on a day the target month does not have, the day pulls back to that month's last day — the rule the TC39 Temporal proposal calls overflow: "constrain". 2026-01-31 + 1 month is 2026-02-28, and the chip names the real dates every time a clamp fires. This is why adding 30 days differs from adding 1 month: the day shift counts 30 actual days to Monday 2026-03-02; the month step holds calendar position and clamps.
Arithmetic is civil and zone-free: proleptic-Gregorian calendar days with no zone rules, so a result never gains or loses a DST hour. Month ends are where tools split — GNU date normalizes overflow instead of clamping, so date -d "2026-01-31 +1 month" prints March 3 (March 2 when February has 29 days). That is why the command under the examples shifts plain days, where every policy agrees.
Examples
2026-01-31 + 1 month2026-02-28The pre-filled sample. February 2026 has no 31st, so the day clamps: Saturday 2026-02-28, 28 days from the start, with the chip naming 2026-01-31 and 2026-02-28.
2026-01-31 + 30 days2026-03-02The same start under a plain day shift: 30 days land on Monday 2026-03-02, two days past the one-month answer.
2024-02-29 + 1 year + 1 month2025-03-28Order at work: the year stage clamps leap day to 2025-02-28 before the month stage reaches Friday 2025-03-28. A single 13-month jump would reach 2025-03-29 instead.
2026-08-07 − 90 days2026-05-09Subtract runs the identical pipeline with the sign flipped: 90 days before 2026-08-07 is Saturday 2026-05-09, day count −90.
Every example on this page is executed against the same engine that powers the tool, on every build.
Gotchas worth knowing
Subtracting clamps too
2026-03-31 − 1 month targets a 28-day February and clamps to 2026-02-28. The chip fires in both directions — clamping is a property of the month step, not of Add.
Leap years move the clamp target
2028-01-31 + 1 month clamps to 2028-02-29, not the 28th: a clamp lands on the target month's real last day, and February's depends on the year.
Clock shifts cross midnight honestly
2026-12-31 23:30 + 45 minutes is 2027-01-01 00:15 — the spill rolls the civil date into the next year, day count 1; subtracting 45 minutes walks it straight back.
Add then subtract is not always a round trip
2026-01-31 + 1 month is 2026-02-28; − 1 month from there is 2026-01-28. A clamp discards the day-of-month, and no later step recovers it.
Ambiguous dates refuse, never guess
03/04/2026 could be two dates depending on locale, so it refuses with the fix spelled out. Harmless variants pass with a chip instead: 2026/01/31 is read as 2026-01-31, and the chip says so.
Common errors
"03/04/2026" could be 3 April or 4 March — type the month name (4 Mar 2026) or use YYYY-MM-DD.- Day/month order is never guessed from digits; the refusal names both readings and the two forms that stay unambiguous.
Months — whole numbers only; for part of a month, use days instead.- Each amount field takes whole units; the hint points one unit down, where the fraction becomes exact.
The days step lands outside the supported date range 0001-01-01 to 9999-12-31.- A shift that leaves years 0001–9999 refuses and names the stage that left the range — a wrapped date is never printed.
FAQ
Why did adding 1 month to January 31 give February 28?
Because February 2026 ends at day 28, the result is constrained to the month's last day instead of spilling into March. The chip prints each exact clamp, and the trace shows the stage where it happened.
Does this calculator account for time zones or DST?
No. Start and result are civil values with no zone attached: nothing springs forward or falls back, and a 24-hour shift equals exactly one calendar day. For wall-clock conversions between zones, use the time zone converter instead.
Can I add business days instead of calendar days?
Not on this page — every calendar day counts, weekends included, and no holiday data is loaded. Skip-weekend deadline arithmetic belongs to the business-days calculator.
Keyboard shortcuts
- ⌘/Ctrl + Enter
- Recompute immediately — results already refresh on every valid edit.
- ⌘/Ctrl + C
- Copy the result date when nothing is selected; a focused field keeps native copy.
- ⌘/Ctrl + Shift + C
- Force-copy the result date past any selection.
- ⌘/Ctrl + S
- Download a time-stamped date-calculator-add-days .txt summary — start, operation, result and day count — instead of the browser's save-page dialog.
- t
- Cycle the color theme; ignored while any field has focus.
- ? or ⌘/Ctrl + /
- Open this page's shortcut help dialog.
- Esc
- Close the topmost open dialog.