🔧 Operation
📅 Date
Years -9999 through 9999 are supported. Negative years are BCE under the proleptic Gregorian calendar.
📅 Anchor date + count
Lists the next or previous occurrences of the anchor's weekday. The anchor date itself is NOT included in the output.
📅 From → To
Distance is signed: negative when "To" is earlier than "From". Zero days means both dates are the same.
📤 Result
{{ weekdayResult.isWeekend ? '🏖️ Weekend' : '💼 Weekday' }}
- ISO date
- {{ weekdayResult.isoDate }}
- Day of week
- {{ weekdayResult.dayOfWeek }}
- Day index (Sun=0)
- {{ weekdayResult.dayIndex }}
- Day index ISO (Mon=1)
- {{ weekdayResult.dayIndexISO }}
- ISO week number
- {{ weekdayResult.weekNumber }}
- Day of year
- {{ weekdayResult.dayOfYear }}
- Days in month
- {{ weekdayResult.daysInMonth }}
📊 Weekday occurrences
- Anchor date
- {{ scanResult.from }}
- Weekday
- {{ scanResult.dayOfWeek }}
- Count requested
- {{ scanResult.count }}
- Direction
- {{ scanResult.count > 0 ? 'Forward' : 'Backward' }}
Dates
📏 Date distance
- From
- {{ distanceResult.from }}
- To
- {{ distanceResult.to }}
- Days
- {{ distanceResult.days }}
- Weeks
- {{ distanceResult.weeks }}
- Remainder days
- {{ distanceResult.weekRemainder }}
- Same weekday?
- {{ distanceResult.sameWeekday ? 'Yes' : 'No' }}
ℹ️ About Day of Week Calculator
What this tool does
The Day of Week Calculator finds the weekday for a calendar date and exposes the companion values people usually need when checking schedules, birthdays, deadlines, logs, and historical dates. It answers three related questions on the proleptic Gregorian calendar:
- Weekday lookup - enter a year, month, and day to get the weekday name, ISO week number, day of year, month length, and weekend/weekday status.
- Weekday scan - list the next or previous occurrences of the same weekday from an anchor date; positive counts scan forward and negative counts scan backward.
- Date distance - measure the signed calendar-day distance between two dates, including whole weeks and remaining days. A multiple-of-7 distance means both dates land on the same weekday.
Calendar definition
All math uses the proleptic Gregorian calendar — the modern leap-year rule (divisible by 4 except centuries not divisible by 400) extended backward in time even for dates before its 1582 adoption. This makes results consistent for software, APIs, and data validation, but it is not the same as asking which local civil calendar a country actually used on a historical date.
BCE input uses astronomical year numbering: year 0 is
1 BCE, -1 is 2 BCE, and so on. Dates are treated as
date-only values, not moments in a timezone, so daylight saving time
and local clock offsets do not change the result.
ISO 8601 week numbering
The week number returned is the ISO 8601 week — the week is defined by its Thursday, weeks start on Monday, and the first week of a year is the one containing the year's first Thursday (equivalently, the one containing January 4). A side effect: January 1 can belong to ISO week 52 or 53 of the previous year, and December 31 can belong to ISO week 1 of the following year.
dayIndex is the conventional 0-based Sunday-first
index (0 = Sunday … 6 = Saturday).
dayIndexISO is the ISO 8601 Monday-first index
(1 = Monday … 7 = Sunday). Both are returned by the API for
convenience.
Practical examples
| Question | Input | Result |
|---|---|---|
| What day is May 26, 2026? | 2026-05-26 | Tuesday, ISO week 22, day 146 of 2026. |
| What weekday was January 1, 2000? | 2000-01-01 | Saturday; it belongs to ISO week 52 of 1999. |
| What weekday was the Apollo 11 landing? | 1969-07-20 | Sunday. |
| When are the next four Tuesdays? | Scan 2026-05-26, count 4 | 2026-06-02, 2026-06-09, 2026-06-16, 2026-06-23. |
| Are two dates the same weekday? | Distance 2026-05-26 to 2026-06-23 | 28 days = 4 weeks, so both dates are Tuesdays. |
Common use cases
- Scheduling: find which weekday a meeting, deadline, release, holiday, or travel date falls on.
- Recurring events: generate the next or previous set of matching weekdays for payroll, invoices, rotations, or maintenance windows.
- Birthday and anniversary checks: answer "what day was I born?" or count how many full weeks separate two dates.
- Historical research: compare dates using one consistent Gregorian rule, while remembering that many regions used Julian or local calendars before adoption.
- Calendar-library testing: cross-check ISO week numbers, leap days, and same-weekday distances against a deterministic implementation.
Limits and interpretation
- Supported years are
-9999through9999; invalid dates such as February 30 are rejected instead of rolled into the next month. - Weekday scans are limited to 366 occurrences in either direction to keep output readable and API responses bounded.
- The distance mode counts calendar days between date-only values. It does not calculate business days, working hours, timezone offsets, or inclusive/exclusive date ranges for payroll rules.
- For historical dates before local Gregorian adoption, the result is a proleptic Gregorian answer. It may differ from a Julian-calendar date recorded in a historical source.
Standards and source references
- ISO 8601 is the source for the internationally understood
YYYY-MM-DDstyle and ISO week-date conventions used throughout this page. - RFC 3339 profiles ISO 8601 for internet timestamps; this tool returns date-only
isoDatestrings in that sortable year-month-day form. - The U.S. Naval Observatory leap-year note summarizes the Gregorian century rule used here: century years are leap years only when divisible by 400.
- For adjacent date tools, use the Leap Year Checker, Week Number Calculator, Date Difference Calculator, or ISO 8601 Formatter.
API Usage Example:
POST /api/tools/time/day-of-week
Content-Type: application/json
{
"operation": "weekday",
"year": 2026,
"month": 5,
"day": 26
}