What is the DAYS function?
=DAYS(end_date, start_date)DAYS returns the number of days between two dates. The result equals end_date minus start_date.
Unlike other date functions, end_date comes first. Reversing the order gives a negative result; move the start date after the end date on the calendar above to see it.
Arguments
- end_date
- The later date.
- start_date
- The earlier date.
DAYS examples
Example 1. Days to Christmas
=DAYS(DATE(2026,12,25), DATE(2026,12,1))December 25 minus December 1 is 24 days.
Example 2. From today to a deadline
=DAYS(B2, TODAY())Recalculates every day how many days are left until the deadline in B2. After the deadline it becomes negative.
Example 3. The same with subtraction
=B2-A2Dates are serial numbers, so plain subtraction gives the same days. If the result cell turns into a date format, change it back to General.
Common mistakes
Arguments reversed
=DAYS(start_date, end_date) gives a negative number. DAYS takes end_date first.
Expecting both ends to count
DAYS subtracts, so December 1 to 25 is 24 days, not 25. Add 1 to count both ends.
FAQ
- Working days only?
- Use NETWORKDAYS to leave out weekends and holidays.
- What if I pass date text?
- According to Microsoft, text that cannot be read as a date gives #VALUE!.