Day of the Week Calculator
This calculator identifies the weekday for a valid calendar date and reports its day-of-year number and leap-year status. It uses Gregorian calendar rules and checks the actual year, month, and day rather than silently rolling an impossible date into another month.
By Dr. Hassan Khames EliwaLast updated
Result
- Day of year
- 321
- Leap year
- No
- Day type
- Weekday
How it works
A calendar date, not a moment in time
Supply a date in YYYY-MM-DD format. The supported range is 0001-01-01 through 9999-12-31, with four digits for the year and two each for month and day. The date picker normally supplies that shape, but the calculation still checks it independently.
The weekday is calculated using UTC calendar components. That is an implementation choice that keeps the result independent of the visitor's computer time zone. It does not mean that a date entered here is a timestamp at midnight in the place where an event happened. No time, offset, or location is requested.
Leap years and ordinal days
Under the Gregorian rule, years divisible by four are leap years, except century years must also be divisible by 400. February therefore has 29 days in 2000 and 2024 but only 28 in 1900. February 29 is rejected when the year fails that rule.
The day-of-year number counts January 1 as day 1. It adds the lengths of preceding months to the day within the selected month. Weekend means Saturday or Sunday in this display; it is not a statement about local working schedules, national holidays, school terms, or religious observances.
Historical dates need context
For consistency, Gregorian rules are extended backward across the entire supported range. Historians call this a proleptic Gregorian calendar. Places adopted the Gregorian system on different dates, so an old document may use a Julian date or another calendar. Convert that document's calendar before interpreting this result as its historical weekday.
Worked example
Leap day in a recent year
Enter 2024-02-29. The results are Thursday, day of year 60, leap year Yes, and day type Weekday. January contributes 31 days, and February contributes another 29 through the selected date, which explains the ordinal result without relying on the weekday calculation.
Changing that input to 2023-02-29 does not return a weekday. It is rejected because February 2023 ended on the 28th. This distinction matters when checking imported records: silently moving that impossible date to March would conceal a source-data problem.
A century boundary
Enter 2000-01-01. The output is Saturday, day of year 1, leap year Yes, and day type Weekend. Although this date occurs before February, the leap-year result describes the entire year. The year 2000 qualifies because it is divisible by 400; a year ending in two zeroes is not automatically a common year.
Expert tips
Common mistakes
- Allowing an importer to normalize bad dates. Some software converts April 31 into a May date. Here, mismatched month lengths fail validation, so correct the original record rather than substituting whatever normalized date another tool returns.
- Assuming every fourth year always qualifies. The century exception matters for historical records and long schedules. Test the complete Gregorian rule instead of counting four-year intervals from a familiar recent leap year.
- Treating a timestamp as a ready-made local date. An event near midnight can have different dates in different locations. Establish the relevant location and calendar date first; this tool deliberately does not convert timestamps.
Frequently asked questions
Does my time zone change the weekday result?
No. The calculation uses the entered calendar date with UTC-based calendar arithmetic, so the same input produces the same weekday in every browser time zone.
Does it recognize public holidays?
No. Weekend is a Saturday-or-Sunday label only. Public holidays, observed substitute days, and country-specific workweeks are outside this calculation.
Can I enter dates before the Gregorian calendar was adopted?
Yes, within the supported year range, but the result applies Gregorian rules backward. It does not reproduce the local historical calendar in use at the time.
Is the day of year the same as an ISO week number?
No. Day of year counts individual days from January 1. ISO week numbering groups dates into weeks and can assign early January dates to the previous week-year.
Why are year zero and short dates rejected?
The accepted format has years 0001 through 9999 and requires YYYY-MM-DD. Year zero, two-digit years, and unpadded month or day values are outside that explicit contract.
Related calculators
Related guides
MathPercentages people get wrong: change, difference and pointsThe denominator determines the answer. Learn to distinguish percentage change, symmetric difference and percentage-point movements.14 November 2026 · 7 min read
MathStandard deviation without the jargonThe average tells you the centre. Standard deviation helps describe the spread, provided you know what the data represents.14 November 2026 · 7 min readSources and standards
About the author
Dr. Hassan Khames Eliwa holds a PhD in Construction & Built Environment and has more than 20 years of international project controls experience. He is Director of Eliwa Project Controls Limited in Auckland and founder of PMMilestone.org and PMMilestone.com.
Buy me a coffee