Summary

To get the last working day in a month, you can use the WORKDAY function together with the EOMONTH function. In the example, the formula in C4 is:

=WORKDAY(EOMONTH(B4,0)+1,-1)

Generic formula

=WORKDAY(EOMONTH(date)+1,-1)

Explanation

Working from the inside out, the EOMONTH function gets the last day of month of any date. To this result, we add 1, which results in the first day of the next month.

This date goes into the WORKDAY function as the "start date", along with -1 for "days". The WORKDAY function automatically steps back 1 day, taking into account any weekends. The result is the last workday of the month.

Holidays

To get the last working day of the month, taking into account holidays, just add the range that contains holiday dates to the formula like this:

=WORKDAY(EOMONTH(B4,0)+1,-1,holidays)

Custom weekends

The WORKDAY function assumes weekends are Saturday and Sunday. If you need to customize weekend days, you can use the WORKDAY.INTL function.

Support Exceljet

Many websites (including Exceljet) have lost over half their traffic in the past year because of the crushing impact of AI on web searches. Exceljet is still at it, publishing free content each week. If you find Exceljet helpful, you can support the site and go ad-free with the Exceljet Lifetime Pass. One payment, no subscription, and ads are gone forever. Plus, you get our Excel Shortcuts video course as a thank you.

Get the Lifetime Pass

Dave Bruns Profile Picture

AuthorMicrosoft Most Valuable Professional Award

Dave Bruns

Hi - I'm Dave Bruns, and I run Exceljet with my wife, Lisa. Our goal is to help you work faster in Excel. We create short videos, and clear examples of formulas, functions, pivot tables, conditional formatting, and charts.