Enter any year to check if it's a leap year and find the nearest leap years before and after it.
A leap year adds an extra day (February 29) to keep our calendar aligned with Earth's orbit around the sun, which takes slightly more than 365 days.
A year is a leap year if it is divisible by 4, EXCEPT century years, which must be divisible by 400.
2024 is a leap year (divisible by 4, not a century year). 2100 will NOT be a leap year, even though it's divisible by 4, because it's a century year not divisible by 400.
Divisible by 4, except century years, which must be divisible by 400 (2000 was a leap year, 1900 was not).
Earth's orbit takes about 365.25 days, so an extra day roughly every 4 years keeps the calendar synced with the astronomical year.
The 365.25-day approximation is slightly too much, so skipping the leap day in most century years fine-tunes the calendar further.