HTML Value Syntax

HTML local date time syntax

Combines a valid date and time with T or a space; normalized datetime-local values use T and a shortest valid time representation. It does not represent an instant until a time zone is chosen separately. This is a value grammar, not a standalone HTML element.

Formal Syntax & Structure

html syntaxhtml
YYYY-MM-DDTHH:mm

Working Example

Example Snippethtml
<label>  Appointment  <input type="datetime-local" value="2026-12-01T09:30"></label>
HTML Reference