The raw calendar distance between two dates — end minus start, leap days included, weekends counted. Three counting conventions measured side by side so you never ship an off-by-one.
Returns a signed whole number of calendar days (gaps). Add 1 for an inclusive count.
The same Jan 15 → Jan 20 span, measured three ways — plus the leap-year spans that break naive 365-day assumptions.
| Expression | Result | Why |
|---|---|---|
| =DAYS(DATE(2024,1,20),DATE(2024,1,15)) | 5 | DAYS: end minus start, exclusive of one endpoint |
| =DATE(2024,1,20)-DATE(2024,1,15) | 5 | Subtraction: identical semantics, no function needed |
| =DAYS(DATE(2024,1,20),DATE(2024,1,15))+1 | 6 | Inclusive: count every calendar day touched |
| =DAYS(DATE(2025,1,15),DATE(2024,1,15)) | 366 | One year across Feb 29, 2024 → 366 |
| =DAYS(DATE(2024,12,31),DATE(2024,1,1)) | 365 | Jan 1 → Dec 31 inside 2024 → 365 gaps |
| =DAYS(DATE(2024,2,29),DATE(2024,2,1)) | 28 | Leap February: Feb 1 → Feb 29 = 28 gaps |
| =DAYS(DATE(2023,2,28),DATE(2023,2,1)) | 27 | Non-leap February: Feb 1 → Feb 28 = 27 gaps |
All presets are exact and engine-stable. Edit the grid dates and every gallery row recomputes live.
8 failure patterns mined from actual user reports on Reddit, Stack Overflow and Super User — each with the authentic symptom, root cause, a fix, and a runnable formula. Not textbook theory.
DAYS requires Excel 2013+; plain date subtraction works in every version and gives identical results.
| Platform | Support | Notes | Gotcha |
|---|
DAYS is one piece. The full course walks the toolkit end to end with live, measured examples.