How to Count Working Days Between Two Dates (and Why Holidays Break the Formula)

Days Between Two Dates

Counting working days looks like simple arithmetic: count the weekdays between two dates, then subtract the holidays. From Tuesday, November 10, 2026 to Thursday, December 31, 2026, that gives 38 weekdays minus three US federal holidays, or 35 working days. Most wrong answers come from three places the arithmetic hides. Tools disagree on whether the first and last days count. Holidays that fall on a weekend move to a weekday, and a holiday list that ignores the move is off by a day. And there is no single holiday calendar: federal offices, the Federal Reserve, the stock market and individual states all close on different days.

The Weekday Count Before Any Holidays

Every seven consecutive days contain exactly five weekdays, so only the leftover days at the end need checking one by one.

Weekdays between two dates, both included
Total days = end โˆ’ start + 1
Full weeks = total days รท 7 (whole number); each contributes 5 weekdays
Remaining days (0 to 6): count the ones that fall Monday to Friday
November 10 to December 31, 2026: 21 + 31 = 52 days
52 = 7 full weeks (35 weekdays) + 3 days (Tue Dec 29, Wed Dec 30, Thu Dec 31)
Weekdays: 35 + 3 = 38

Over a whole year the same logic gives 260, 261 or 262 weekdays. A common year is 52 weeks plus one day, and a leap year 52 weeks plus two, so the total depends on which weekdays those extra days land on. Both 2026 and 2027 have 261 weekdays; 2028, a leap year that starts on a Saturday, has 260; and 2032, a leap year that starts on a Thursday, will have 262. How those days turn into working hours is covered in working hours in a year.

Do the First and Last Days Count?

The single most common discrepancy between two working-day calculations is not about holidays at all. It is about the endpoints. Tools treat them differently, and none of them is wrong; they answer slightly different questions.

Method Start date End date November 10 to December 31, 2026
Excel and Google Sheets NETWORKDAYS Counted Counted 35 working days (federal holidays)
Python numpy.busday_count Counted Not counted 34 working days (federal holidays)
Subtracting one date from the other Not counted Counted 51 calendar days, not 52

Microsoft’s documentation shows the inclusive behavior with its own example: January 1 to January 31, 2006, gives 22 working days, which only works if both ends are counted. NumPy’s documentation states that the end dates are excluded from the count. The two conventions differ by exactly one day whenever the end date is a working day. For a contract that says work must be done “within 10 business days,” or a deadline counted from a filing date, the convention is part of the rule, and the difference between counting a span and counting an interval is explained in time interval.

Why a Correct Holiday List Still Gives the Wrong Answer

Spreadsheet functions accept a list of holidays and subtract only those that fall on working days inside the range. A holiday on a Saturday subtracts nothing, because Saturday was never counted. That design is correct, but it exposes a trap: in the United States, a holiday that falls on a weekend is usually observed on a weekday instead.

Under 5 U.S.C. 6103(b) and Executive Order 11582, as summarized by the Office of Personnel Management, federal employees on a Monday-to-Friday schedule get a Saturday holiday on the preceding Friday and a Sunday holiday on the following Monday. Independence Day 2026 fell on Saturday, July 4, so federal offices closed on Friday, July 3. A holiday list containing “July 4, 2026” silently counts July 3 as a working day, and the total for any range that includes it is one day too high.

Holiday Date Observed by federal offices Effect if the list uses the actual date
Independence Day 2026 Saturday, July 4 Friday, July 3 One day too many
Juneteenth 2027 Saturday, June 19 Friday, June 18 One day too many
Independence Day 2027 Sunday, July 4 Monday, July 5 One day too many
Christmas 2027 Saturday, December 25 Friday, December 24 One day too many
New Year’s Day 2028 Saturday, January 1, 2028 Friday, December 31, 2027 One day too many in 2027

The Year With an Extra Holiday

The last row of that table produces a calendar oddity. Because New Year’s Day 2028 falls on a Saturday, its observed holiday is Friday, December 31, 2027, inside the previous year. 2027 therefore contains twelve weekday federal holidays instead of the usual eleven, and 2028 only ten, because its New Year’s Day has already been observed in 2027.

Year Weekdays Federal holidays on weekdays Federal working days
2026 261 11 250
2027 261 12 (including December 31 for New Year’s Day 2028) 249
2028 260 10 250

A holiday list built only from each year’s own holidays misses the extra date. For 2027 it finds eleven holidays and counts 250 working days instead of 249. The fix is to build the list from observed dates and to check the first days of the following January for a holiday that moves back into December.

Whose Holidays Are You Counting?

The observance rule above applies to federal employees. Other institutions follow different rules, which means “business days” in a contract, a bank transfer and a stock trade can mean three different things.

Date (2027) Federal offices Federal Reserve (bank payments) NYSE and Nasdaq
Friday, March 26 (Good Friday) Open Open Closed
Monday, October 11 (Columbus Day) Closed Closed Open
Thursday, November 11 (Veterans Day) Closed Closed Open
Friday, December 24 (Christmas observed) Closed Open Closed
Friday, December 31 (New Year’s Day observed) Closed Open Open

The Federal Reserve does not move Saturday holidays to Friday, so its payment systems stay open on December 24 and 31, 2027. The New York Stock Exchange closes for Good Friday, which is not a federal holiday, and trades on Columbus Day and Veterans Day, which are. Its rule for Saturday holidays also has an exception for the end of an accounting period, which is why it does not close on Friday, December 31, 2027. The 2026 exchange calendar, including the Friday, July 3 closure, is in stock market holidays 2026.

States add their own layer. Massachusetts and Maine observe Patriots’ Day on the third Monday in April, a working day almost everywhere else. A working-day count for an office in Boston and one for an office in Chicago can differ for the same range, and a company with staff in several states may need a separate holiday list for each location.

Moving Holidays Break Hard-Coded Lists

Most federal holidays are not fixed dates. Martin Luther King Jr. Day, Washington’s Birthday, Memorial Day, Labor Day and Columbus Day fall on set Mondays, and Thanksgiving on the fourth Thursday of November, so their dates change every year, as explained in why some holidays change date. A holiday list copied from last year’s spreadsheet is wrong for at least six holidays.

Lists also go stale when the law changes. Juneteenth became a federal holiday in June 2021. Templates and payroll calculators built before then count June 19, or its observed weekday, as a working day unless someone updated them.

Working Weeks That Are Not Monday to Friday

The standard functions assume a Saturday-Sunday weekend. Excel and Google Sheets offer NETWORKDAYS.INTL for everything else. Its weekend argument takes a code or a seven-character string of 1s and 0s, one per day starting with Monday, where 1 marks a non-working day.

Working-day formulas in spreadsheets and code
Standard week: =NETWORKDAYS(A2, B2, Holidays)
Friday-Saturday weekend: =NETWORKDAYS.INTL(A2, B2, 7, Holidays)
Sunday only off: =NETWORKDAYS.INTL(A2, B2, 11, Holidays)
Custom (Monday to Thursday working): =NETWORKDAYS.INTL(A2, B2, “0000111”, Holidays)
Date 10 working days after A2: =WORKDAY(A2, 10, Holidays)
Python, end date excluded: numpy.busday_count(start, end, holidays=list)

WORKDAY works in the opposite direction, returning the date a given number of working days later, and it does not count the start date itself. Microsoft notes that a weekend string of seven 1s always returns zero, and that NETWORKDAYS.INTL returns a negative number when the start date is later than the end date. NumPy follows the same sign convention.

Checking a Count Before You Rely on It

Three checks catch most errors. First, confirm the endpoint convention: if the answer must include both the first and last day, a tool that excludes the end date will be one short whenever that day is a working day. Second, compare the holiday list against observed dates, not calendar dates, and look past December 31 for a New Year’s Day that falls on a Saturday. Third, make sure the holiday list matches the institution the deadline belongs to: a court or federal agency, a bank, an exchange or a particular state. For the November 10 to December 31, 2026 example, the federal answer is 35 working days, the Federal Reserve gives the same 35, and the NYSE count is 36, because the exchange trades on Veterans Day.

 


Sources and references

US Office of Personnel Management: Federal Holidays, In Lieu Of Determination
The rule moving Saturday holidays to Friday and Sunday holidays to Monday for federal employees
Microsoft Support: NETWORKDAYS.INTL Function
Weekend codes, the seven-character weekend string and how holidays are excluded
↑
โœ•Close Menu