HTML Value Syntax
HTML date syntax
A calendar date uses a positive year with at least four digits, a two-digit month and a two-digit day. The day must exist in the given Gregorian month and year. No time zone is encoded. This is a value grammar, not a standalone HTML element.
Formal Syntax & Structure
html syntaxhtml
YYYY-MM-DDWorking Example
Example Snippethtml
<label> Date <input type="date" value="2024-02-29"></label>