User Rating 0.0 โ˜…โ˜…โ˜…โ˜…โ˜…
Total Usage 0 times
Category Time
Quick dates:
Is this tool helpful?

Your feedback helps us improve.

โ˜… โ˜… โ˜… โ˜… โ˜…

About

An invalid date propagated through a financial system, a database, or an engineering log can corrupt records irreversibly. February 29 in a non-leap year, September 31, or any date falling within the Gregorian reform gap (October 5-14, 1582) are common sources of silent data corruption. This tool validates dates against the full proleptic Gregorian and Julian calendar rule sets. It computes the leap year status using the divisibility chain (y รท 4, exception at 100, counter-exception at 400 for Gregorian; simple y รท 4 for Julian), resolves the day of week via Zeller's congruence, and outputs the Julian Day Number for astronomical cross-referencing.

The validator rejects impossible dates outright and flags ambiguous historical dates near the 1582 reform boundary. It also returns the ISO 8601 week number, the day-of-year ordinal, and the quarter. Note: this tool uses the proleptic Gregorian calendar for dates before October 15, 1582, which is a mathematical extension and may not match historical records of regions that adopted the Gregorian reform later (e.g., Britain in 1752, Russia in 1918). Pro tip: always specify which calendar system your source data uses before storing historical dates.

date validator calendar checker leap year gregorian julian date verification day of week iso week

Formulas

Gregorian leap year predicate:

L = (y mod 4 = 0) โˆง (y mod 100 โ‰  0 โˆจ y mod 400 = 0)

Where y = year, L = TRUE if leap year.

Julian Day Number (Gregorian calendar):

JDN = 367y โˆ’ floor(7(y + floor(m + 912))4) + floor(275m9) + d + 1721013.5

Where y = year, m = month, d = day.

Zeller's congruence for day of week (Gregorian):

h = (q + floor(13(m + 1)5) + K + floor(K4) + floor(J4) โˆ’ 2J) mod 7

Where q = day of month, m = month (3 = March โ€ฆ 14 = February, with Jan/Feb counted as months 13/14 of the previous year), K = year of century (y mod 100), J = zero-based century (floor(y รท 100)), h = day of week (0 = Saturday โ€ฆ 6 = Friday).

ISO 8601 week number is computed by finding the Thursday of the target week and counting weeks from January 1 of that Thursday's year.

Reference Data

MonthDays (Common Year)Days (Leap Year)QuarterDay-of-Year Start (Common)Day-of-Year Start (Leap)
January3131Q111
February2829Q13232
March3131Q16061
April3030Q29192
May3131Q2121122
June3030Q2152153
July3131Q3182183
August3131Q3213214
September3030Q3244245
October3131Q4274275
November3030Q4305306
December3131Q4335336
Gregorian Leap Year Rule
Divisible by 4Leap year candidate
Divisible by 100Not a leap year (exception)
Divisible by 400Leap year (counter-exception)
Julian Leap Year Rule
Divisible by 4Always a leap year
Notable Calendar Reform Dates
Gregorian reform (Papal)Oct 15, 1582
Britain & coloniesSep 14, 1752
RussiaFeb 14, 1918
GreeceMar 1, 1923
TurkeyJan 1, 1926
ISO 8601 Week Numbering
Week starts onMonday
Week 1 containsJanuary 4
Weeks per year52 or 53

Frequently Asked Questions

When Pope Gregory XIII reformed the calendar in 1582, the dates October 5 through October 14 were skipped entirely to correct the accumulated drift of the Julian calendar. These 10 dates never existed in the Gregorian system. The validator flags any date in this gap as invalid. If you are working with historical records from a region that adopted the reform later (e.g., Britain in 1752), switch to Julian mode for dates before that region's adoption date.
The Julian calendar uses a simple rule: any year divisible by 4 is a leap year. The Gregorian calendar adds two exceptions: years divisible by 100 are not leap years unless they are also divisible by 400. This means the year 1900 is a leap year in the Julian calendar but not in the Gregorian calendar. The year 2000 is a leap year in both systems because it satisfies the 400-year counter-exception.
The Julian Day Number (JDN) is a continuous count of days since the beginning of the Julian Period on January 1, 4713 BC (proleptic Julian calendar). Astronomers use it to avoid ambiguity between calendar systems and to simplify date arithmetic. For example, to find the number of days between two dates, subtract their JDNs. The JDN for January 1, 2000 (Gregorian) is 2451545.
Yes. Enter the year as a negative number or zero. Year 0 corresponds to 1 BCE in astronomical year numbering (ISO 8601). The proleptic Gregorian and Julian calendars extend backward indefinitely, so the leap year rules still apply. Note that no civilization used either calendar system before its invention, so these dates are mathematical constructs.
ISO 8601 defines week 1 as the week containing the first Thursday of the year (equivalently, the week containing January 4). Weeks start on Monday. This means December 29-31 may belong to week 1 of the following year, and January 1-3 may belong to week 52 or 53 of the previous year. The validator computes this correctly by finding the Thursday of the target date's week and determining which year that Thursday falls in.
No. Calendar date validity is purely arithmetic. A date is valid or invalid regardless of timezone or locale. However, the day-of-week result assumes the proleptic Gregorian or Julian calendar without timezone adjustments. If you need to validate a date-time with timezone awareness (e.g., does February 29 exist in UTC+14?), the date portion is still governed by the same leap year rules.