EpochLab

Date Validator

Is this a real date?

Checks that a date exists as well as parses — 31 February and 29 February in a common year both parse fine in most languages, and neither is a date.

Questions people ask

The things that come up about date validators, answered plainly.

Why does 2023-02-30 not throw an error in my code?

Because most date constructors roll over rather than reject: JavaScript's `new Date(2023, 1, 30)` silently gives 2 March. That is a validation bug waiting to happen, and it is the main thing this page checks for.

Is 29 February 2100 valid?

No. 2100 divides by 100 but not 400, so it is a common year. It is the century exception that most hand-written leap-year checks get wrong.

Related tools

Julian days, Excel serials, GPS time, cron expressions and format validators.

All 160 tools · More in converters & validators