Date Calculator Guide: Why Date Math Is Harder Than It Looks
How many days are between January 1 and March 1? The answer is 59 in a common year and 60 in a leap year — and in 2024, which was a leap year, many automated systems got it wrong. Date arithmetic sounds trivial but involves leap years, month-length variations, time zone transitions, and DST skips. Here's how to get it right every time.
Key Takeaways
- Leap year rule: divisible by 4, EXCEPT centuries must be divisible by 400 (2000 was a leap year; 1900 was not)
- Calendar days vs business days: "30 business days" excludes weekends — equals ~6 weeks of calendar time
- Date "difference" can be ambiguous: Jan 1 to Jan 2 is "1 day apart" but spans parts of 2 calendar days
- February is the trap month: adding "1 month" to January 31 can't land on February 31 — different languages handle this differently
- Unix timestamps are seconds since Jan 1, 1970 UTC — the most unambiguous way to store a moment in time
How Leap Years Work (and Why 2000 Was Special)
The Gregorian calendar rule for leap years: a year is a leap year if it's divisible by 4 — except for years divisible by 100, which are NOT leap years, unless they're also divisible by 400, in which case they ARE leap years. This gives a calendar year average of 365.2425 days, very close to the actual solar year of 365.24219 days.
Leap Years
- ✓ 2024 (divisible by 4)
- ✓ 2028 (divisible by 4)
- ✓ 2000 (divisible by 400)
- ✓ 1600 (divisible by 400)
Not Leap Years
- ✗ 1900 (century, not divisible by 400)
- ✗ 2100 (century, not divisible by 400)
- ✗ 2025 (not divisible by 4)
- ✗ 2026 (not divisible by 4)
Days in Each Month (The Rhyme and the Math)
Jan
31
Feb
28
Mar
31
Apr
30
May
31
Jun
30
Jul
31
Aug
31
Sep
30
Oct
31
Nov
30
Dec
31
Mnemonic: knuckles = 31-day months; valleys = 30-day (or 28/29 for Feb). Start with January on first knuckle.
Calendar Days vs Business Days
Many legal, financial, and HR contexts use "business days" — weekdays (Monday–Friday) excluding weekends. Some definitions also exclude federal holidays. The difference is significant: 30 calendar days ≈ 21–22 business days; 30 business days ≈ 42–44 calendar days (6 weeks).
| Context | Calendar Days | Business Days |
|---|---|---|
| Shipping (standard) | 5–7 days | 5–7 days (same) |
| Legal response deadlines | Often calendar | Sometimes business — check the statute |
| Payroll/HR notices | Often 30 calendar | Often 30 business = 6 weeks |
| Contract payment terms (Net 30) | 30 calendar days | — |
| SEC filing extensions | 15 calendar days | — |
Calculate Dates Instantly
Date Calculator
Calculate days between two dates, add or subtract days from any date, find the day of the week, and count business days excluding weekends and holidays.
Open Date Calculator →