Excel NETWORKDAYS Function
The Microsoft Excel NETWORKDAYS function calculates the number of working days between two dates (the start date and end date) with weekends excluding automatically by default. Besides, it is optional to specify holidays to exclude from the working days.
Note: The NETWORKDAYS function includes both the start date and end date when calculating working days.
Syntax
=NETWORKDAYS( start_date, end_date, [holidays] )
Arguments
Start_date (Required): It is the start date of the date range.
End_date (Required): It is the end date of the date range
Holidays (Optional): It is an optional range which includes one or more dates to exclude from the working days. The holidays list can be one of the below:
- A range of cells that contains the dates.
- An array of the serial numbers that represent the dates.
For these three arguments, you can directly reference to cells containing start date, end date and dates of holidays:
=NETWORKDAYS( B3, C3,F3:F4 )
Or directly enter dates as text string with quotation marks embraced:
=NETWORKDAYS( "12/20/2018", "1/10/2019",{"12/25/2018","1/1/2019"})
Return value
Numerical value
The NETWORKDAYS function will return a number representing number of working days between two dates.
Function notes
1. Supposing a cell has no specific format, when entering date into it, the date will be stored as sequential serial number. Referencing to cells with these kind of serial numbers can also be used in NETWORKDAYS function calculation.
(By default, the serial number 1 representing January 1, 1900, and the serial number 40909 representing January 1, 2012 because it is 40,909 days after January 1, 1900.)
2. The #VALUE! Error value will return when any one of the arguments contains invalid date.
3. The NETWORKDAYS function will ignore any time values when calculating working days.
Examples
This section will show you examples of how to calculate working days between two given days in Excel.
Example 1: Calculate working days between two dates by excluding default weekends
As below screenshot shown, the start dates place in range B3:B5, and the end dates place in range C3:C5. For calculating only working days between the start and end dates, and automatically excluding weekends, please do as follows.
1. Select the cell you will display the total working days, copy the below formula into it and press the Enter key.
=NETWORKDAYS( B3, C3 )
2. Keep selecting the result cell, drag the Fill Handle down to apply the formula to other cells. See screenshot:
Now the number of working days between specified start date and end date are calculated
Example 2: Calculate working days between two dates by excluding both weekends and holidays
If you want to exclude specified holidays as well, method in this section can help you.
1. Select the cell you will display the total working days, copy the below formula into it and press the Enter key.
=NETWORKDAYS( B3, C3,F3:F4 )
Here, F3:F4 is the list of holidays you will exclude from the working days.
2. Keep selecting the result cell, drag the Fill Handle down to apply the formula to other cells. See screenshot:
More Examples
How to add days to date including or excluding weekends and holidays in Excel?
How to add number of business/working days or hours to a date in Excel?
The Best Office Productivity Tools
Kutools for Excel - Helps You To Stand Out From Crowd
Kutools for Excel Boasts Over 300 Features, Ensuring That What You Need is Just A Click Away...
Office Tab - Enable Tabbed Reading and Editing in Microsoft Office (include Excel)
- One second to switch between dozens of open documents!
- Reduce hundreds of mouse clicks for you every day, say goodbye to mouse hand.
- Increases your productivity by 50% when viewing and editing multiple documents.
- Brings Efficient Tabs to Office (include Excel), Just Like Chrome, Edge and Firefox.