About the Day of the Week Calculator
This tool tells you which day of the week any calendar date fell on — or will fall on — for any year from 1 through 9999. Enter a month, day, and year, and it returns the weekday name, the ISO 8601 weekday number, the date's position within its year, and how many days separate it from today.
The formula: Julian Day Number
The calculator converts your date into a Julian Day Number (JDN) — a continuous day count used in astronomy and calendar software, where JDN 0 corresponds to Monday, January 1, 4713 BCE (proleptic Julian calendar). It uses the integer-arithmetic form published by Richards:
a = floor((14 − month) / 12)
y = year + 4800 − a
m = month + 12a − 3
JDN = day + floor((153m + 2) / 5) + 365y + floor(y/4) − floor(y/100) + floor(y/400) − 32045
Once you have the JDN, JDN mod 7 gives the weekday directly (0 = Monday, 1 = Tuesday, … 6 = Sunday for this particular offset). This is mathematically equivalent to the more commonly taught Zeller's Congruence, which computes the same weekday through a slightly different set of month/century terms — both methods agree on every date because they are built on the same underlying calendar arithmetic.
Reading the four results
- Day of the week — the weekday name (Monday through Sunday) for your date.
- ISO weekday number — the ISO 8601 convention, where Monday = 1 and Sunday = 7. (Note this differs from JavaScript's
Date.getDay(), which numbers Sunday = 0 through Saturday = 6.) - Day of year — how many days into the year your date falls, counting January 1 as day 1. Leap years run 1–366; common years run 1–365.
- Days from today — the signed difference between your date's JDN and today's JDN, so you can see at a glance how far in the past or future the date sits.
Assumptions and limits
The calculator applies the proleptic Gregorian calendar — today's leap-year rule (a year is a leap year if divisible by 4, except centuries not divisible by 400) — to every year in range, including years long before the Gregorian calendar existed. This matches how JavaScript's Date object and most modern software handle historical dates, but it will not match the calendar a given country was actually using before it adopted the Gregorian reform (most of Catholic Europe switched in 1582; Britain and its colonies in 1752; other countries later still). For dates after each region's own Gregorian adoption, the result is exact.