Excel functions · Dates

NETWORKDAYS function in Excel

NETWORKDAYS counts the working days between two dates, Monday to Friday, leaving out weekends and any holidays you list. Both the start and end dates are counted when they're working days. For a different weekend, such as Friday and Saturday, use NETWORKDAYS.INTL.

Last reviewed

Syntax

=NETWORKDAYS(start_date, end_date, [holidays])
=NETWORKDAYS.INTL(start_date, end_date, [weekend], [holidays])
start_daterequired
The first date. Counted if it's a working day.
end_daterequired
The last date. Counted if it's a working day.
holidaysoptional
A range of dates to leave out, such as public holidays.
weekendoptional
NETWORKDAYS.INTL only: which days are the weekend. 1 is Saturday and Sunday (the default), 7 Friday and Saturday, 11 Sunday only; or a 7-character string such as "0000011" starting Monday, where 1 means a day off.
  • If start_date is after end_date, the result is negative.
  • Holidays that fall on a weekend aren't subtracted twice.
  • WORKDAY does the reverse: a date a set number of working days away.

Which versions have NETWORKDAYS

Every current Excel version: Microsoft 365, Excel for the web, Excel 2024, 2021, 2019 and 2016, on Windows and Mac.

NETWORKDAYS availability by Excel version
VersionHas it
Microsoft 365 (Windows and Mac)Yes
Excel for the webYes
Excel 2024Yes
Excel 2021Yes
Excel 2019Yes
Excel 2016Yes

Google Sheets

Google Sheets has NETWORKDAYS and NETWORKDAYS.INTL with the same arguments.

Examples

The examples use these sample ranges on one sheet.

Project (A1:C2)
RowABC
1TaskStartEnd
2December build2026-12-012026-12-31
Holidays (E1:E3)
RowE
1Holidays
22026-12-25
32026-12-28
  1. 1.Working days in December 2026

    =NETWORKDAYS(B2, C2)

    Result: 23

    December 2026 has 31 days, 8 of them Saturdays or Sundays.

  2. 2.Leave out holidays

    =NETWORKDAYS(B2, C2, E2:E3)

    Result: 21

    25 December (a Friday) and 28 December (a Monday) are both weekdays, so 2 more days drop out.

  3. 3.A Sunday-only weekend

    =NETWORKDAYS.INTL(B2, C2, 11)

    Result: 27

    Weekend code 11 means only Sundays are off; December 2026 has 4 Sundays.

Common errors and fixes

NETWORKDAYS errors, causes and fixes
ErrorWhy it happensFix
#VALUE!A date, or a cell in holidays, is text that Excel can't read as a date.Make sure every date is a real date, not text.
#NUM! or #VALUE!NETWORKDAYS.INTL got a weekend code or string it doesn't recognise.Use a listed code such as 1, 7 or 11, or a 7-character string of 0s and 1s.

Do it with GPTExcel

Skip writing NETWORKDAYS by hand

Upload your Excel or CSV file to Chat and ask in plain English. GPTExcel writes the formula for your file and your version of Excel or Google Sheets.

your-file.xlsx

Count the working days for each project, excluding the holidays on my Holidays sheet.

Done. I used NETWORKDAYS on your sheet and checked the results against your data.

your-file-updated.xlsxYour original stays unchanged
  • Written for your platform and version
  • Checked against your actual data
  • Newest functions looked up in official docs
Try it free Formula Generator

Free plan, no credit card.

NETWORKDAYS questions

Does NETWORKDAYS include the start and end date?
Yes. Both dates are counted when they're working days, so Monday to Friday of one week is 5.
How do I count working days with a Friday–Saturday weekend?
Use NETWORKDAYS.INTL with weekend code 7: =NETWORKDAYS.INTL(B2, C2, 7, E2:E3).

Skip the formula hunt

Upload a spreadsheet and ask in plain English. Free plan, no credit card.

Start free