Excel Weekdays Between Dates: Formulas, Holidays, and Tips

Formulas & functions · Updated November 19, 2026

To count weekdays between two dates in Excel, use =NETWORKDAYS(A2,B2), with the start date in A2 and the end date in B2. It counts Monday through Friday and includes both dates when they fall on working days; add a holiday range or use NETWORKDAYS.INTL to adjust the rules.

The basic NETWORKDAYS formula

In Microsoft Excel for Microsoft 365 on Windows, enter your starting date in one cell and your ending date in another, then use NETWORKDAYS. The function’s basic syntax is NETWORKDAYS(start_date,end_date,[holidays]). The holidays argument is optional, and the default weekend is Saturday and Sunday.

For example, with January 1, 2025 in A2 and January 10, 2025 in B2, enter =NETWORKDAYS(A2,B2) in another cell. The result is 8: January 1, 2, and 3, followed by January 6 through 10, are eight Monday-to-Friday dates. January 4 and 5 are weekend days, so they are not counted.

The result is a number, not a date. If Excel displays a date instead of a count, select the result cell and choose Home > Number Format > General, or choose a numeric format. The formula itself does not change the dates or create a list of weekdays; it returns the count.

What Excel means by weekdays between dates

NETWORKDAYS counts eligible dates inclusively. That means it considers the start date and end date as possible working days. If both dates are weekdays, both can contribute to the result. If either date is a Saturday, Sunday, or listed holiday, that date is not counted.

This inclusive rule is a frequent source of off-by-one differences. From Monday to Friday in the same week, NETWORKDAYS returns 5, not 4, because Monday and Friday are both included. By contrast, subtracting one date from another gives the number of elapsed midnight-to-midnight intervals, not the number of working dates in the inclusive period.

Decide what your question means before choosing a formula. For a payroll period, service window, or schedule that includes both its first and last dates, the inclusive count is often appropriate. For a measure of workdays after a starting date, the first date may need to be left out; that is a different counting convention, not an Excel error.

Exclude public holidays and other nonworking dates

To omit holidays, put the dates in a range and supply that range as the third argument. With January 1, 2025 in A2, January 10, 2025 in B2, and January 1, 2025 entered as an actual date in H2, =NETWORKDAYS(A2,B2,H2:H2) returns 7. It subtracts the holiday from the eight weekdays in the interval.

For a longer holiday list, use a range such as H2:H20 in place of H2:H2. The list can include company closures, observed holidays, or other dates your organization treats as nonworking. Dates outside the start-to-end interval do not affect the count. A holiday that falls on a weekend does not reduce the count again, because that date was already excluded as a weekend.

  • Enter each holiday as a genuine Excel date value, not text that only looks like a date.
  • Keep the holiday range limited to the date cells; blank cells in a referenced range are ignored.
  • Check whether your organization observes a holiday on a nearby weekday when the calendar date falls on a weekend. Excel does not infer observed days; include the actual nonworking date in the list.

Different countries, employers, and teams may follow different holiday calendars. Excel cannot determine which dates apply to a particular person or location, so the accuracy of the result depends on the list you provide.

Choose custom weekends with NETWORKDAYS.INTL

When the weekend is not Saturday and Sunday, use NETWORKDAYS.INTL. Its syntax is NETWORKDAYS.INTL(start_date,end_date,[weekend],[holidays]). The weekend argument can be a numeric code or a seven-character pattern that represents Monday through Sunday, where 1 means a nonworking day and 0 means a working day.

For example, if Friday and Saturday are the weekend, the numeric weekend code is 7. With the same January 1–10, 2025 dates in A2 and B2, =NETWORKDAYS.INTL(A2,B2,7) returns 6. In that span, Friday, January 3 and Friday, January 10 are excluded along with Saturday, January 4; the remaining six dates are working days under that schedule.

NETWORKDAYS.INTL also accepts a custom weekend pattern when the workweek does not match one of its standard weekend codes. For instance, a pattern can mark Sunday as the only day off, or can represent another regular combination. Count the seven characters from Monday to Sunday and use 1 for each nonworking day. If you also need to omit holidays, add the holiday range as the fourth argument.

Do not confuse a weekend setting with a holiday list. The weekend argument defines a recurring weekly pattern; the holiday argument identifies particular dates. Use both when your calendar has a regular schedule plus occasional closures.

When to use a different counting convention

If you need the number of calendar dates in a range, including both endpoints, subtract the start date from the end date and add 1. With January 1, 2025 in A2 and January 10, 2025 in B2, =B2-A2+1 returns 10 calendar days. That is not a weekday count, because it includes Saturday and Sunday.

If you want working days after the starting date through and including the ending date, start the NETWORKDAYS calculation one day later. With the same dates in A2 and B2, =NETWORKDAYS(A2+1,B2) returns 7. January 1 is left out, while January 2 through January 10 are evaluated normally. If your rule excludes the ending date instead, adjust the ending date rather than assuming NETWORKDAYS does so automatically.

These distinctions matter in reports that compare elapsed time, inclusive service periods, and completed workdays. Agree on whether the first and last dates count before comparing figures from different systems or people.

Set up date cells and check the result

Excel stores recognized dates as numbers, which is why date arithmetic and these functions work. A cell can display a date in a familiar format while still holding a numeric date value. Text imported from another system may look identical but fail to behave as a date, especially when the source and workbook use different regional date conventions.

To reduce ambiguity, enter dates using a format Excel recognizes in your regional settings, or build dates with Excel’s date-entry tools. Check a suspicious value by changing the cell’s number format to General: a recognized date will display its underlying serial number. Restore a date format afterward if needed. The formula result cell should normally use General or a number format.

For a quick manual check, list the dates in the interval and mark which are weekdays, then remove any holidays and apply the chosen weekend pattern. This is especially useful when the count is important or the interval crosses a year boundary. A simple spot check can reveal a missing holiday, a text date, or an endpoint assumption that was not made explicit.

Common problems and fixes

  • The answer is one day different: Check whether the formula includes both endpoints and whether your intended rule excludes the start or end date.
  • A holiday is still counted: Confirm that the holiday range is supplied as the optional argument and that its entries are real dates within the interval.
  • The result is unexpectedly large or small: Verify that the cells contain the intended dates, not text, and that the start and end cells have not been swapped.
  • Friday or another workday is excluded: Check the weekend code or seven-character pattern in NETWORKDAYS.INTL. The default NETWORKDAYS schedule assumes Saturday and Sunday are off.
  • The formula displays as text: Make sure the cell is not formatted as Text, remove any leading apostrophe, and re-enter the formula.

For shared workbooks, label the holiday list and weekend convention near the calculation. A bare number can be difficult to interpret later if nobody knows whether it includes holidays, observed days, or both endpoints.

Frequently Asked Questions

Does NETWORKDAYS include the start and end dates?
Yes. It evaluates both endpoints and counts each one if it is a working day under the selected weekend and holiday rules.

How do I count weekdays while excluding holidays?
Put the holiday dates in a cell range and use that range as the third argument of NETWORKDAYS. For a custom weekend, use NETWORKDAYS.INTL and supply the holiday range after the weekend argument.

Can Excel count weekdays when Friday and Saturday are the weekend?
Yes. Use NETWORKDAYS.INTL with weekend code 7. You can also use a seven-character Monday-to-Sunday pattern to define a custom weekly schedule.

Why does Excel return a different answer from date subtraction?
Date subtraction measures elapsed calendar days, while NETWORKDAYS counts eligible working dates and includes both endpoints. Choose the method that matches whether you need calendar duration or workdays.

Can I count business days between dates in Excel for Mac or the web?
NETWORKDAYS and NETWORKDAYS.INTL are Excel worksheet functions, so the formulas work in Microsoft 365 for Mac and Excel for the web as well as Windows. Menu locations and date-entry behavior can vary by platform, but the function arguments and counting rules remain the same.

Related

Try it: the Formula Explainer: paste any formula and see each function and reference in plain English.

More in Formulas & functions

Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources

Spotted an error in this guide? Let us know.