Date Calculator — Days Between & Add/Subtract
Find the exact number of days, weeks, months, or years between two dates, or add and subtract spans of time from a starting date. Includes a business-day mode that excludes weekends. Runs entirely in your browser.
Advertisement
How to use
- Step 1: Choose mode: Days Between or Add/Subtract
- Step 2: Pick the start date
- Step 3: Enter the end date or the amount to add/subtract
- Step 4: Toggle 'Exclude weekends' for business-day counts
- Step 5: Read the result and breakdown
How date math works
The calculator uses real calendar arithmetic via JavaScript's Date object and the date-fns library, which together handle leap years, varying month lengths (28-31 days), daylight-saving-time shifts, and time-zone differences.
Days Between mode computes the absolute difference between two calendar dates. It returns the result in years (full), months (full), weeks (full), and days (total) — letting you choose whichever unit matters most.
Add/Subtract mode takes a start date and shifts it by a given amount. Adding "1 month" preserves the day-of-month when possible; if the target month is shorter (e.g. adding 1 month to Jan 31 lands on Feb 28/29), date-fns clamps to the last valid day.
Business-day mode excludes Saturdays and Sundays. It does not currently account for public holidays, which vary by country. For tighter business-day math, subtract national-holiday counts manually.
Advertisement
Examples
| Start | Jan 1, 2026 |
|---|---|
| End | Dec 31, 2026 |
| Calendar days | 364 |
| Business days | 260 |
| Years / Months / Weeks | 0 / 11 / 52 |
| Start | May 6, 2026 |
|---|---|
| Add | + 90 days |
| Result | Aug 4, 2026 |
| Day of week | Tuesday |
| Start | Mar 31, 2026 |
|---|---|
| Subtract | − 6 months |
| Result | Sep 30, 2025 |
| Note | End-of-month clamping handled automatically |