Weekend days between two dates
January 2024 holds 8 weekend days, 4 Saturdays and 4 Sundays. Enter any two dates and get the same split for your own range, both ends included, for staffing plans, overtime rules or leave counts. Free in your browser.
- Free
- Runs in your browser
- No sign-up
- Your data stays on your device
Run — free
Worked example
- Start
- 2024-01-01
- End
- 2024-01-31
- Jdn start
- 2,460,311
- Jdn end
- 2,460,341
- Start weekday
- Monday
- End weekday
- Wednesday
Knowing how many weekend days fall between two calendar dates is a practical need in staffing plans, overtime rules, travel booking, event logistics, and personal leave math. People search for a weekend-days-between-dates calculator when they want Saturdays and Sundays counted separately or as a total, not a raw day span that still has to be filtered by hand. This tool accepts two strict ISO dates in year-month-day form, validates that each day truly exists on the Gregorian calendar including leap-year Februaries, converts both to astronomical Julian Day Numbers with a pure integer formula, and reports how many Saturdays and Sundays land on every civil day from the earlier date through the later date inclusive. Order does not change the weekend totals: the same pair yields the same Saturday and Sunday counts whether you list the earlier day first or second, while signed day direction remains available for chronological pipelines. Impossible bases such as the twenty-ninth of February in a common year fail with a clear validation error instead of wrapping silently.
How Saturdays and Sundays are counted in a date range
Begin with two civil calendar dates written as year, month, and day in the international ISO form with hyphens and fixed widths so every client agrees on the same six integers.
For each string confirm that the year lies in a practical Gregorian range from year one through nine thousand nine hundred ninety-nine, that the month is between one and twelve, and that the day exists for that month under Gregorian leap rules: a year is a leap year when it is divisible by four, except that century years are leap years only when they are also divisible by four hundred.
That rule makes February twenty-nine legal in years such as two thousand twenty-four and two thousand, and illegal in two thousand twenty-three and nineteen hundred. When both triples are valid, convert each civil day to an astronomical Julian Day Number with the Fliegel and Van Flandern integer formula used across the date family. Take the inclusive span from the smaller day number through the larger so order never changes the count.
Weekday follows the modular identity day-of-week equals Julian day plus one modulo seven with Sunday as zero and Saturday as six, matching the well-known civil weekday of the Unix epoch. Whole weeks inside the span each contribute exactly one Saturday and one Sunday; any remainder of at most six days is scanned from the earlier weekday so long multi-year ranges stay constant time.
Where weekend-day counters show up in real work
Operations managers estimate weekend coverage headcount for stores, hospitals, and call centers from a schedule window defined by two ISO dates. HR and payroll teams compute premium weekend hours or rest-day entitlements without importing a full calendar library or trusting a browser clock. Event planners and travel desks count weekend nights inside a stay or festival window for pricing tiers and staffing.
Data engineers materialize derived columns for weekend exposure, campaign rest days, and on-call load from two ISO strings stored in configuration. If you later need business-day counts that skip weekends and holidays, whole weeks plus leftover days, pure day addition to a single base, or day-of-year ordinals alone, treat those as separate search intents and landings rather than overloading this weekend-days-between-dates page.
What you can do with it
Staffing and weekend coverage
Count Saturdays and Sundays inside a schedule window so operations can size weekend shifts, on-call rosters, and premium pay without a full calendar library.
Leave and rest-day entitlements
Derive how many weekend days fall between two ISO leave dates for policy checks, travel days, and HR configuration that must ignore host time zones.
Events, stays, and campaign windows
Measure weekend nights or weekend exposure for festivals, hotel stays, and marketing campaigns defined by two calendar ISO strings.
FAQ
What if one of the dates is invalid?
Examples include 2023-02-29, 2024-04-31, wrong shapes, or missing fields. Invalid input is not charged.
Does this skip holidays or use Friday–Saturday weekends?
No. It counts Saturday and Sunday only on the proleptic Gregorian calendar. Business days with holidays and custom weekend definitions are separate tools and landings.
What does it cost?
The browser tool is free and runs locally.
Are both the first and the last date counted?
Yes. Every day from the earlier date through the later one is checked, both included, so a range that starts and ends on the same Saturday counts one Saturday.
How many weekend days are in January 2024?
There are 8: 4 Saturdays and 4 Sundays across its 31 days. Enter 2024-01-01 as the first date and 2024-01-31 as the second to see the count split by day.
Related tools
For developers — API access
Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.
API endpoint
Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.
Call it from your stack
curl -X POST https://api.kit.forhosting.com/date/weekend-count \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"start":"2024-01-01","end":"2024-01-31"}'const res = await fetch("https://api.kit.forhosting.com/date/weekend-count", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"start": "2024-01-01",
"end": "2024-01-31"
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/date/weekend-count",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"start": "2024-01-01",
"end": "2024-01-31"
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/date/weekend-count", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"start":"2024-01-01","end":"2024-01-31"}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"start":"2024-01-01","end":"2024-01-31"}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/date/weekend-count", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"start": "2024-01-01",
"end": "2024-01-31"
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "date.weekend_count",
"status": "queued",
"_links": {
"result": "/tasks/tsk_…/result"
}
}The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.
Pricing
Published price — no tokens, no invented credits. A failed task is never charged.
Errors
| HTTP | Code | Meaning |
|---|---|---|
401 | unauthorized | Missing or invalid API key. |
402 | insufficient_balance | Your balance doesn't cover the task price. |
404 | unknown_type | That task type doesn't exist. |
429 | rate_limited | Too many requests. Use the webhook instead of polling. |
Technical notes
What you send and what you get back
Send two required string fields: start and end, each a strict ISO calendar day such as two thousand twenty-four hyphen zero one hyphen zero one and two thousand twenty-four hyphen zero one hyphen three one. Classic checks include the full month of January two thousand twenty-four with four Saturdays and four Sundays for eight weekend days, a single Saturday same-day range with saturdays equal to one, and a Monday-through-Friday workweek with zero weekend days. Missing fields, non-string values, strings that do not match the four-two-two digit pattern, and dates that match the pattern but are not real calendar days all fail with invalid_input and are not charged. On success the response echoes the normalized start and end ISO strings, the Julian Day Number for each side, English weekday names for both endpoints, signed_days as end minus start, total_days_inclusive as the number of civil days in the closed interval, saturdays and sundays as separate integer counts, weekend_days as their sum, a direction flag of forward, backward, or same, and a short formula string that documents the JDN path. Pricing for successful API calls is the published base of $0.002 per item; validation failures do not consume prepaid balance.
Where weekend-day counters show up in real work
Because this capability is a pure parse engine, API pricing is the published base of $0.002 per successful item and failed validation does not consume balance.
Technical questions
Are both endpoint dates included?
Yes. Every civil day from the earlier date through the later date inclusive is considered. If start and end are the same Saturday, saturdays is 1 and weekend_days is 1.
Does input order change the weekend count?
No. The absolute inclusive range is used for saturdays, sundays, and weekend_days. signed_days and direction still reflect end minus start for chronological pipelines.