Datetime Tools
Leap year checker.
Enter any year and we'll tell you whether it's a leap year under the real Gregorian calendar rule, plus the nearest leap years before and after it.
Inputs
Result
Enter a year and press Check year.
The leap year rule
A year is a leap year in the Gregorian calendar if it satisfies one of these conditions, checked in order:
- It is divisible by 400 — always a leap year (e.g. 2000).
- It is divisible by 100 but not by 400 — not a leap year (e.g. 1900, 2100).
- It is divisible by 4 but not by 100 — a leap year (e.g. 2024, 2028).
- Otherwise, it is not a leap year (e.g. 2026, 2027).
The extra day, February 29, exists because Earth's orbit takes about 365.2422 days, not an even 365. Adding a day every 4 years overcorrects slightly, so centuries not divisible by 400 skip the leap day to keep the calendar aligned with the seasons over the long run.
Worked example: 1900, 2000, 2024 and 2100
- 2024: 2024 / 4 = 506 exactly, and 2024 is not a multiple of 100, so it is a leap year with 366 days.
- 1900: divisible by 4 and by 100 but 1900 / 400 = 4.75, so it is not a leap year. February 1900 had 28 days.
- 2000: divisible by 400 (2000 / 400 = 5), so it is a leap year.
- 2100: divisible by 100 but not by 400 (2100 / 400 = 5.25), so it is not a leap year, even though 2100 / 4 = 525.
Over any 400-year cycle this gives 97 leap years and 303 ordinary years, an average of 365.2425 days per year (146,097 days in 400 years), close to the tropical year of about 365.2422 days.
Sources
Checked
- RFC 3339, Appendix C: Leap Years (the leap_year function)
- POSIX.1-2017 Base Definitions, 4.16 Seconds Since the Epoch (the year/4, year/100, year/400 terms)
- Python documentation: calendar, which uses the proleptic Gregorian calendar and provides isleap()
Sources retrieved 26 October 2026. Runs entirely in your browser. Nothing you type is sent or stored.
Frequently asked questions
Is 2026 a leap year?
No. 2026 is not divisible by 4, so February has 28 days. The next leap years are 2028 and 2032.
Why is 2100 not a leap year?
2100 is divisible by 100 but not by 400, so the Gregorian rule skips it. 2000 was a leap year because it is divisible by 400.
How many days are in a leap year?
366 days: the usual 365 plus February 29. February has 29 days instead of 28.
Does the rule work for years before 1582?
The rule is the Gregorian one, applied backwards ("proleptic"). Countries adopted the Gregorian calendar at different times, so historical dates before adoption may follow the Julian rule (every fourth year) instead.
Worked example: 1900, 2000, 2024 and 2026
The Gregorian rule is checked in this order: divisible by 400 means leap; otherwise divisible by 100 means not leap; otherwise divisible by 4 means leap.
| Year | Rule that applies | Leap year? |
|---|---|---|
| 1900 | Divisible by 100 but not 400 | No |
| 2000 | Divisible by 400 | Yes |
| 2024 | Divisible by 4, not by 100 | Yes |
| 2026 | Not divisible by 4 | No (nearest leap years 2024 and 2028) |
Next steps: day of the year calculator, day of the week you were born, Julian day converter, or RFC 3339 timestamp validator.