The DAYS function returns the number of days between two dates. Both dates must be valid Excel dates or text values that can be parsed as dates. The DAYS function only works with whole numbers, fractional time values are ignored. If start and end dates are reversed, DAYS returns a negative number. The DAYS function returns all days between two dates, to calculate working days between dates, see the NETWORKDAYS function.
Storing and parsing text values that represent dates should be avoided, because it can introduce errors and parsing problems. Working with native Excel dates (which are numbers) is a better approach. To create a numeric date from scratch in a formula, use the DATE function.
The DAYS function only works with whole numbers and ignores time.
If dates are not recognized, DAYS returns the #VALUE! error.
If dates are out of range, DAYS returns the #NUM! error.
Dates in Excel are serial numbers that start on 1/1/1900, which is 1.
In the example, the formula in cell D6 simply subtracts the numeric value of 1/1/1999 (36161) from the numeric value of 1/1/2000 (36526) to get a...
The Excel DAYS360 function returns the number of days between two dates based on a 360-day year, where all months are assumed to have 30 days. For example, the formula =DAYS360("1-Jan-2021","31-Dec-2021") returns 360 days.
The Excel NETWORKDAYS function calculates the number of working days between two dates. NETWORKDAYS automatically excludes weekends (Saturday and Sunday) and can optionally exclude a list of holidays supplied as dates.
The Excel NETWORKDAYS.INTL function calculates the number of working days between two dates. NETWORKDAYS.INTL can optionally exclude a list of holidays and provides a way to specify which days of the week are considered weekends.