
Maintenance
Part of Workday counts for a month: why length and starting weekday decide the total
How to calculate working days per month and per fiscal period in Excel
Build monthly working-day counts with EOMONTH and NETWORKDAYS, check them against OPM's 2027 federal closures, and assemble a fiscal span with a reverse check.
A month is an awkward span to give a spreadsheet, because the two dates that define it are derived rather than typed. This page builds the month from two functions, shows where the arguments go wrong, then uses the result for a 2027 month-by-month table and a fiscal span that crosses a year end. Holiday figures are for United States federal closures and are labelled as such.
What to take away
EOMONTH(start_date, 0)gives the last day of a month as a serial number.NETWORKDAYSbetween the first and last day returns the weekdays of the whole month, and both end dates are inside the count.- Pass dates built with
DATE, not typed text. Microsoft says text dates can cause problems and that an invalid date returns#VALUE!. - 2027 has 261 weekdays. The eleven closures in OPM's 2027 federal schedule leave 250.
- OPM lists the observed New Year's Day for 2028 on Friday 31 December 2027, under its 2028 table. Counted by calendar date, 2027 therefore has a twelfth weekday closure and 249 working days.
- A fiscal span is one
NETWORKDAYScall from its first date to its last date. Monthly counts are the cross-check, not a second method.
The month as two cells
With a month's first day in A2:
last day =EOMONTH(A2,0)
weekdays =NETWORKDAYS(A2,EOMONTH(A2,0))
next first =EOMONTH(A2,0)+1
Microsoft documents that EOMONTH returns a serial number for the last day of the month a given number of months away. A positive second argument moves forward, a negative one back, and a non-integer is truncated. If the cell shows a five-figure number, format it as a date; the value is right. An invalid start date returns #NUM!.
DATE(y, m+1, 1)-1 gives the same last day, because Microsoft's DATE function adds a month argument above 12 to the following year. EOMONTH is the shorter formula and states the intent.
Both ends count
Microsoft describes NETWORKDAYS as returning whole working days between two dates, and its own example from 1 October 2012 to 1 March 2013 returns 110. Counting weekdays with both of those dates in gives 110; leaving the start out gives 109. So the function includes both ends, and adding 1 to "make the month inclusive" counts a day twice.
| Span in 2027 | NETWORKDAYS returns | Why |
|---|---|---|
| 1 March to 31 March | 23 | Whole month, both ends in |
| 1 March to 8 March | 6 | Monday 1st to Monday 8th |
| 5 March to 5 March | 1 | A single weekday counts as one |
| 6 March to 6 March | 0 | A Saturday counts as nothing |
Editorial suggestion: test a reversed pair such as 8 March to 1 March in your own workbook before relying on it. The Microsoft page does not describe that case.
Weekend and holiday arguments
NETWORKDAYS fixes Saturday and Sunday as the weekend. For any other week use NETWORKDAYS.INTL. Its weekend argument is either a number code (1 is Saturday and Sunday, 11 is Sunday only, 17 is Saturday only) or a seven-character string read from Monday, where 1 marks a non-working day and 0 a working day. Only 0 and 1 are allowed. 0000011 is Saturday and Sunday, and 1111111 always returns 0. A string of the wrong length or with other characters returns #VALUE!.
The holidays argument takes a range of dates or an array constant. Order does not matter. A listed date that falls on a rest day cannot lower the count, because that day was never counted. Keep every closure as a real date value: build them with DATE or import them in ISO order, and check that the whole range is numeric before trusting a total that moved. The desk's notes on text-date failures and on workday formulas for other countries go further.
Microsoft also warns that the results of DATEVALUE can vary with the computer's system date setting. A text date such as 03/04/2027 may be 4 March or 3 April depending on the setting, so a closure list typed as text can shift without any error.
The 2027 month-by-month table
This table is for United States federal closures only. The Office of Personnel Management publishes the federal holiday schedule, and its 2027 table lists these eleven dates: 1 January, 18 January, 15 February, 31 May, 18 June, 5 July, 6 September, 11 October, 11 November, 25 November and 24 December. Three are observed dates. Juneteenth falls on Saturday 19 June and is observed Friday 18 June. Independence Day falls on Sunday 4 July and is observed Monday 5 July. Christmas Day falls on Saturday 25 December and is observed Friday 24 December.
The Saturday rule comes from 5 U.S.C. 6103(b): for employees whose basic workweek is Monday through Friday, the Friday before is the holiday. For Sundays, OPM's footnote cites Section 3(a) of Executive Order 11582 (11 February 1971): for most federal employees the following Monday is treated as the holiday. These rules govern federal pay and leave. A court, a state agency or a private employer can observe different dates.
| Month | Weekdays | Federal closures | Working days |
|---|---|---|---|
| January | 21 | 2 | 19 |
| February | 20 | 1 | 19 |
| March | 23 | 0 | 23 |
| April | 22 | 0 | 22 |
| May | 21 | 1 | 20 |
| June | 22 | 1 | 21 |
| July | 22 | 1 | 21 |
| August | 22 | 0 | 22 |
| September | 22 | 1 | 21 |
| October | 21 | 1 | 20 |
| November | 22 | 2 | 20 |
| December | 23 | 1 | 22 |
| Year | 261 | 11 | 250 |
Each monthly figure is NETWORKDAYS with the OPM list as the third argument. The year row is the check: twelve monthly counts must sum to 261 without closures and 250 with them. If your sum is 365, the weekend is not being applied.
The twelfth closure sits in December. OPM prints the observed New Year's Day for 2028, Friday 31 December 2027, in its 2028 table. A sheet that loads only the 2027 table shows December as 22. A sheet that includes 31 December shows 21 and a year total of 249. Neither is a formula error. They answer "OPM's 2027 table" and "every federal weekday closure dated in 2027". Decide which one the document wants. The long-run reasoning is in working days per year and the dated list is in working days per year with 2027 holidays.
A fiscal span: April 2027 to March 2028
Write down the first and last date and whether each counts before using a yearly total. The span below runs from 1 April 2027 to 31 March 2028, both included. It is not the federal fiscal year: the U.S. Treasury's fiscal year begins on October 1 and ends on September 30 under 31 U.S.C. 1102. A company or a state can use other boundaries.
Step 1: list the months with EOMONTH, one row per month, and get weekdays and closures. Step 2: sum. Step 3: compare with a single call.
| Month | Weekdays | Federal closures | Net |
|---|---|---|---|
| April 2027 | 22 | 0 | 22 |
| May 2027 | 21 | 1 (31 May) | 20 |
| June 2027 | 22 | 1 (18 June) | 21 |
| July 2027 | 22 | 1 (5 July) | 21 |
| August 2027 | 22 | 0 | 22 |
| September 2027 | 22 | 1 (6 Sep) | 21 |
| October 2027 | 21 | 1 (11 Oct) | 20 |
| November 2027 | 22 | 2 (11, 25 Nov) | 20 |
| December 2027 | 23 | 2 (24, 31 Dec) | 21 |
| January 2028 | 21 | 1 (17 Jan) | 20 |
| February 2028 | 21 | 1 (21 Feb) | 20 |
| March 2028 | 23 | 0 | 23 |
| Span | 262 | 11 | 251 |
The 2028 closures come from OPM's 2028 table: 31 December 2027 (observed New Year's Day), 17 January and 21 February 2028. The single-cell check is =NETWORKDAYS(DATE(2027,4,1),DATE(2028,3,31),Closures), where Closures holds the 2027 table plus 31 December 2027, 17 January 2028 and 21 February 2028 (listed dates outside the span, such as 1 January 2027, do no harm), and it must return 251. For a span that starts mid-month, use the real start date for that partial month and not the full month.
The federal fiscal year 2027, 1 October 2026 to 30 September 2027, works the same way. It has 261 weekdays. OPM's tables show eleven closures inside it: 12 October, 11 November, 26 November and 25 December 2026, then 1 January, 18 January, 15 February, 31 May, 18 June, 5 July and 6 September 2027. The net is 250.
Reverse-check a reported total
Work backwards from a claim. Suppose a report states 253 working days for the April 2027 to March 2028 span (a hypothetical figure). The baseline is 262, so the report implies nine closures. The OPM list has eleven. Ask for its dated closure list and compare each entry with the span and the week pattern.
Two things usually explain a gap. A closure may be missing, for example the observed 31 December that appears in the other year's table. Or a closure may be dropped because the list was copied from the wrong year. A count of entries is not enough: an entry outside the span, or on a rest day, does not reduce the total.
Editorial suggestion: keep an audit record beside the number: first date, last date, endpoint rule, week pattern, closure list with its source and retrieval date, and the monthly counts. For how the monthly closed-form works without a sheet, see working days per month. For layers of national and state calendars, see state and regional calendars.
Sources
- [Microsoft
- NETWORKDAYS function](https://support.microsoft.com/en-us/office/networkdays-function-48e717bf-a7a3-495f-969e-5005e3eb18e7)
- [Microsoft
- NETWORKDAYS.INTL function](https://support.microsoft.com/en-us/office/networkdays-intl-function-a9b26239-4f20-46a1-9ab8-4e925bfd5e28)
- [Microsoft
- EOMONTH function](https://support.microsoft.com/en-us/office/eomonth-function-7314ffa1-2bc9-4005-9d66-f49db127d628)
- [Microsoft
- DATE function](https://support.microsoft.com/en-us/office/date-function-e36c0c8c-4104-49da-ab83-82328b832349)
- [Microsoft
- DATEVALUE function](https://support.microsoft.com/en-us/office/datevalue-function-df8b07d4-7761-4a93-bc33-b7471bbff252)
- [U.S. Office of Personnel Management
- Federal holidays](https://www.opm.gov/policy-data-oversight/pay-leave/federal-holidays/)
- [5 U.S.C. 6103
- Holidays (govinfo)](https://www.govinfo.gov/content/pkg/USCODE-2023-title5/html/USCODE-2023-title5-partIII-subpartE-chap61-subchapI-sec6103.htm)
- [31 U.S.C. 1102
- Fiscal year (govinfo)](https://www.govinfo.gov/content/pkg/USCODE-2023-title31/html/USCODE-2023-title31-subtitleII-chap11-sec1102.htm)







