To calculate working days between two dates in Excel, use the WORKDAY or WORKDAY.INTL function. 1. Use WORKDAY with a start date and workdays to add/subtract, e.g., =WORKDAY(A1,5). 2. For custom weekends, apply WORKDAY.INTL with a weekend code or string like "0000011". 3. Include holidays by adding a holiday range, e.g., B1:B5. Ensure dates are valid, formatted correctly, and holiday lists are accurate to avoid errors.
If you need to calculate working days between two dates in Excel, the WORKDAY
function is a solid tool. It helps you skip weekends and even holidays if needed. Here’s how to use it effectively.

Basic Use of WORKDAY
At its core, WORKDAY
calculates a date that is a certain number of workdays ahead or behind a start date. The default setup assumes a Monday–Friday workweek.
To use it, you just need two things: a start date and the number of workdays to add (or subtract). For example:

=WORKDAY(A1, 5)
This means: starting from the date in cell A1, give me the date 5 workdays later. If A1 is a Monday, the result will be Friday.
You can also use negative numbers to go backward. Like this:
=WORKDAY(A1, -3)
gives you the date 3 workdays before A1.
One thing to remember: make sure your cell is formatted as a date, or you’ll see a serial number instead of a readable date.

Custom Weekends with WORKDAY.INTL
If your schedule doesn’t follow the standard Mon–Fri pattern—say, you work Tue–Sat or have a 4-day week—you should use WORKDAY.INTL
. This version lets you define which days are weekends.
The syntax looks like this:
=WORKDAY.INTL(start_date, days, [weekend], [holidays])
The key part here is the [weekend]
argument. You can either use a preset code (like 11 for Sunday only, 17 for Saturday only) or a custom string of 7 digits (1s and 0s) representing each day of the week.
For instance:
"0000011"
means Saturday and Sunday are weekends."1000000"
means Monday is the only weekend day.
So if you want to move 4 workdays forward from A1, but your weekend is Thursday and Friday, you’d write:
=WORKDAY.INTL(A1, 4, "0011000")
Adding Holidays
Both WORKDAY
and WORKDAY.INTL
can account for holidays. Just provide a range or list of holiday dates as the last argument.
Say your company has holidays listed in cells B1:B5. Your formula might look like:
=WORKDAY(A1, 10, B1:B5)
Or with WORKDAY.INTL
:
=WORKDAY.INTL(A1, 10, 1, B1:B5)
Here, 1
sets the weekend as Sat–Sun by default. Make sure the holiday list includes actual dates and no extra text or blanks, or the function might throw an error.
A few tips:
- Dates must be valid Excel dates (not text).
- Holidays should be in chronological order, though it usually still works if they’re not.
- Always double-check that your holiday range is absolute (e.g.,
$B$1:$B$5
) if you plan to copy the formula down a column.
That’s basically all you need to get started with the WORKDAY
function. It’s not complicated, but small mistakes—like wrong date formats or missing holidays—can throw off your results.
The above is the detailed content of how to use the workday function in excel. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undress AI Tool
Undress images for free

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

MicrosoftTeams’freeversionlimitsmeetingsto60minutes.1.Thisappliestomeetingswithexternalparticipantsorwithinanorganization.2.Thelimitdoesnotaffectinternalmeetingswhereallusersareunderthesameorganization.3.Workaroundsincludeendingandrestartingthemeetin

Grouping by month in Excel Pivot Table requires you to make sure that the date is formatted correctly, then insert the Pivot Table and add the date field, and finally right-click the group to select "Month" aggregation. If you encounter problems, check whether it is a standard date format and the data range are reasonable, and adjust the number format to correctly display the month.

Quick Links Check the File's AutoSave Status

To set up the repeating headers per page when Excel prints, use the "Top Title Row" feature. Specific steps: 1. Open the Excel file and click the "Page Layout" tab; 2. Click the "Print Title" button; 3. Select "Top Title Line" in the pop-up window and select the line to be repeated (such as line 1); 4. Click "OK" to complete the settings. Notes include: only visible effects when printing preview or actual printing, avoid selecting too many title lines to affect the display of the text, different worksheets need to be set separately, ExcelOnline does not support this function, requires local version, Mac version operation is similar, but the interface is slightly different.

The tutorial shows how to toggle light and dark mode in different Outlook applications, and how to keep a white reading pane in black theme. If you frequently work with your email late at night, Outlook dark mode can reduce eye strain and

It's common to want to take a screenshot on a PC. If you're not using a third-party tool, you can do it manually. The most obvious way is to Hit the Prt Sc button/or Print Scrn button (print screen key), which will grab the entire PC screen. You do

MicrosoftTeamsrecordingsarestoredinthecloud,typicallyinOneDriveorSharePoint.1.Recordingsusuallysavetotheinitiator’sOneDriveina“Recordings”folderunder“Content.”2.Forlargermeetingsorwebinars,filesmaygototheorganizer’sOneDriveoraSharePointsitelinkedtoaT

Finding the second largest value in Excel can be implemented by LARGE function. The formula is =LARGE(range,2), where range is the data area; if the maximum value appears repeatedly and all maximum values ??need to be excluded and the second maximum value is found, you can use the array formula =MAX(IF(rangeMAX(range),range)), and the old version of Excel needs to be executed by Ctrl Shift Enter; for users who are not familiar with formulas, you can also manually search by sorting the data in descending order and viewing the second cell, but this method will change the order of the original data. It is recommended to copy the data first and then operate.
