How to Calculate the Days Between Two Dates, Step by Step
Subtract the earlier date from the later one: 3 March to 19 March is 16 days, or 17 counting both ends. Month lengths, leap days and weekdays-only counts.
To find the days between two dates, subtract the earlier date from the later one. From 3 March to 19 March 2026 that is 19 − 3 = 16 days. If you also want to count the first day (an event that runs through both dates, say), the answer is 17. Both are correct; they answer different questions, so decide which one you need before you count. The days between dates calculator does either with one switch.
Exclusive or inclusive: the one-day question
The plain difference does not count the starting day, just as the distance from 3 to 19 on a ruler is 16, not 17. Adding 1 gives the count of calendar days that both dates touch.
| Method | Calculation, 3 to 19 March 2026 | Result | Use it for |
|---|---|---|---|
| Exclusive (end minus start) | 19 − 3 | 16 days | Elapsed time, “how long until”, ages in days |
| Inclusive (both dates count) | 19 − 3 + 1 | 17 days | A trip or event that runs through both dates |
The same logic gives 1 day from 1 January to 2 January (exclusive) and 2 days inclusive. When a form says “within 10 days”, check whether the start day is day 0 or day 1.
Counting across months of different lengths
Within one month, subtract the day numbers. Across months, add up the pieces: the days left in the first month, every full month in between, and the day number in the last month.
| Piece | Working | Days |
|---|---|---|
| Rest of January after the 14th | 31 − 14 | 17 |
| February 2026 | full month | 28 |
| March 2026 | full month | 31 |
| 1 April to 3 April | day number | 3 |
| 14 January to 3 April 2026 | 17 + 28 + 31 + 3 | 79 |
Month lengths are in the table near the end of this guide.
Crossing a leap day
A 29 February inside the range adds one day. The leap year rule is in how leap years work; the effect on a count looks like this:
| Range | Year type | Days |
|---|---|---|
| 20 February to 10 March 2026 | Common | 18 |
| 20 February to 10 March 2024 | Leap | 19 |
| 1 March 2023 to 1 March 2024 | Contains 29 February 2024 | 366 |
| 1 March 2024 to 1 March 2025 | No 29 February inside | 365 |
Multiplying years by 365 is off by a day whenever a leap day is crossed, so count the calendar instead.
Days until and days since a date
“Days until” is the future date minus the starting date; “days since” is the starting date minus the past date. Both use the same subtraction, with fixed dates here so the answers do not move:
| Question | Calculation | Days |
|---|---|---|
| Days from 1 November to 25 December 2026 | 25 Dec − 1 Nov | 54 |
| Days from 8 November to 31 December 2026 | 31 Dec − 8 Nov | 53 |
| Days from 4 July to 8 November 2026 | 8 Nov − 4 Jul | 127 |
| Days from 1 January to 8 November 2026 | 8 Nov − 1 Jan | 311 |
To go the other way, from a date plus a number of days to a new date, use add days to a date.
Calendar days versus business days
Calendar days count every day. Business days here are Monday to Friday, counted after the start date up to and including the end date.
| Range | Calendar days | Business days (Mon–Fri) |
|---|---|---|
| Wed 4 March to Wed 18 March 2026 | 14 | 10 |
| Mon 2 March to Fri 27 March 2026 | 25 | 19 |
| Fri 6 March to Mon 9 March 2026 | 3 | 1 |
The first row is two whole weeks: 14 days contain 4 weekend days, leaving 10. In the second, 25 days contain 6 weekend days. Ten business days after Friday 6 March 2026 is Friday 20 March, 14 calendar days later. Holidays are not in these figures; the business days calculator can skip them.
Turning days into weeks and months
For weeks, divide by 7 and keep the remainder as days: 79 days is 11 weeks and 2 days (11 × 7 + 2), and 311 days is 44 weeks and 3 days. For a calendar-aligned count of weeks, see weeks between two dates.
For months, add whole calendar months first, then count the leftover days. From 14 January, two months reaches 14 March, and 14 March to 3 April is 20 more days: 2 months and 20 days, even though the span is 79 days. Months vary in length, so there is no exact conversion; on average a month is 30.4369 days (365.2425 ÷ 12), so 79 days is about 2.6 months. If the start day is missing from the target month, the usual convention is the last day: one month after 31 January 2026 is 28 February, so 31 January to 1 March reads as 1 month and 1 day (29 days).
Days from 1 January to the start of each month
For a long count, look up both dates here and subtract. Each figure is the days elapsed from 1 January to the 1st of that month; for another day of the month, add the day number minus 1.
| Month starts | Days in month | Normal year | Leap year |
|---|---|---|---|
| January | 31 | 0 | 0 |
| February | 28 / 29 | 31 | 31 |
| March | 31 | 59 | 60 |
| April | 30 | 90 | 91 |
| May | 31 | 120 | 121 |
| June | 30 | 151 | 152 |
| July | 31 | 181 | 182 |
| August | 31 | 212 | 213 |
| September | 30 | 243 | 244 |
| October | 31 | 273 | 274 |
| November | 30 | 304 | 305 |
| December | 31 | 334 | 335 |
Worked example in 2026, a normal year: 8 November is 304 + 7 = 311 days after 1 January, matching the earlier table. That is day 312 of the year, which the week number lookup shows next to the week.
Spreadsheet formulas
In Excel and Google Sheets, =B1-A1 gives the exclusive difference for two date cells, and =DATEDIF(A1,B1,"d") returns the same figure. =NETWORKDAYS(A1,B1) counts Monday to Friday and includes both the start and the end date, so for 4 and 18 March 2026 it returns 11 where this guide’s convention gives 10. The functions count differently, which is why two sources can disagree by one.
Every figure in this guide was computed with Python’s datetime module.
If you need hours and minutes rather than whole days, see how to add and subtract time.
Updated 2026-11-08