Business day calculator

Count business days between two dates, excluding Saturdays and Sundays. Include or exclude either endpoint, then subtract US federal holidays or bank holidays for England and Wales, Scotland, or Northern Ireland.

Loading the calculator…

Including the start and end dates changes the count

For a Monday-to-Friday range with no holidays, these settings produce different totals. A checked endpoint only counts if it is a working day.

Including the start and end dates changes the count
Dates countedBusiness days
Monday through Friday5
Tuesday through Friday4
Tuesday through Thursday3

Which holiday calendar should I use?

Weekdays only counts Monday through Friday without removing public holidays. US federal holidays removes published federal employee holidays, including observed substitute dates. The three UK options remove published bank holidays for the selected region. State-specific US holidays, company shutdowns and individual work schedules are not included.

Copy count and rules keeps the total, dates, endpoint settings, calendar, and deductions together, so someone receiving the number can see how it was calculated.

How substitute holidays are counted

A published substitute weekday can be excluded even when the holiday's usual date is on a weekend. Two holiday names on the same date remove one day. A holiday already excluded as a weekend is not subtracted again.

Build a business day calculator

Count Monday through Friday locally, then exclude applicable public holidays from the Holiday API. Dates are compared as UTC calendar days, not elapsed local hours. US federal holidays uses country US and region null; the example keeps the UK region explicit. Use the published observed dates and filter out observances.

  1. Choose which endpoints to include and a supported holiday region.
  2. Load every year in the range and require each calendar to succeed.
  3. Deduplicate holiday dates and remove only holidays that land on weekdays.

Installation steps are included in each example. Set PARSEAPI_KEY on your server. Swift and Kotlin use an app key restricted to your app ID.

// npm install @parseapi/sdk@1.14.0
import { parseAPI } from '@parseapi/sdk';

// Set PARSEAPI_KEY on your server.
const parse = parseAPI();

const start = '2026-12-21', end = '2027-01-04';
const country = process.argv[2] ?? 'GB'; // GB or US (federal employee holidays).
const includeStart = true, includeEnd = true, region = country === 'GB' ? 'ENG' : '';
const day = value => {
  if (!/^\d{4}-\d{2}-\d{2}$/.test(value)) throw new Error('Invalid date.');
  const date = new Date(value + 'T00:00:00Z');
  if (!Number.isFinite(+date) || date.toISOString().slice(0, 10) !== value) throw new Error('Invalid date.');
  return +date / 86400000;
};
const first = day(start) + (includeStart ? 0 : 1);
const last = day(end) - (includeEnd ? 0 : 1);
if (day(end) < day(start)) throw new Error('End must follow start.');
const firstYear = Number(start.slice(0, 4)), lastYear = Number(end.slice(0, 4));
if (lastYear - firstYear >= 5) throw new Error('Use at most five calendar years.');
const calendars = await Promise.all(Array.from({ length: first <= last ? lastYear - firstYear + 1 : 0 }, async (_, index) => {
  const year = firstYear + index;
  const result = await parse.holiday(country, { year });
  if (result.country !== country || result.year !== year || !Array.isArray(result.holidays)) {
    throw new Error('Could not verify the holiday calendar.');
  }
  return result.holidays.filter(row => row.type === 'public' &&
    (row.regions === null || row.regions.includes(region)));
}));
const holidays = new Set(calendars.flat().map(row => row.date));
let count = 0;
for (let value = first; value <= last; value++) {
  const date = new Date(value * 86400000);
  const weekend = date.getUTCDay() === 0 || date.getUTCDay() === 6;
  if (!weekend && !holidays.has(date.toISOString().slice(0, 10))) count++;
}
console.log({ country, start, end, includeStart, includeEnd, region, businessDays: count });

// Select US for federal employee holidays; regional/state and employer closures are outside that scope.

Holiday API documentation

Are the start and end dates included?

Both are included by default, but you can exclude either one. An included endpoint only adds to the total when it is a Monday-to-Friday working day under the selected calendar.

Does the business day calculator exclude public holidays?

Choose US federal holidays or one of the three UK bank-holiday calendars. The calculator loads the selected calendar for every counted year, filters out observances and subtracts only holidays on counted weekdays. Weekdays only does not subtract holidays.

Why might my workplace count a different number of business days?

This tool uses a Monday-to-Friday week. Company closures, personal schedules, other weekend patterns, and special deadline rules are not included. Select the applicable UK calendar or use Weekdays only if you want a count without holiday adjustment.

Can I copy the working-day total with its rules?

Yes. Copy count and rules includes the two dates, the total, endpoint settings, selected calendar, weekend and holiday deductions, and the named weekday holidays excluded.

Can this add a number of business days to a date?

This tool counts business days between two dates. To add ordinary calendar days, weeks, months, or years, use the date calculator. Those shifts include weekends and holidays.

How large a date range can I calculate?

Choose dates within five calendar years, with the end on or after the start. A holiday-adjusted result requires the published calendar for every counted year in the range.

Does this include observed US federal holidays?

Yes. US federal holidays uses the published federal employee calendar, including substitute weekdays when a holiday falls on a weekend. State holidays and employer-specific closures are not included. For example, July 3, 2026 is the published observed Independence Day date.