What are Date and Time inputs?

Last modified: July 1st, 2025

Date and Time inputs are editing interfaces for date and time values. You can use these inputs in the Data Editor, Content Editor, or Visual Editor to edit structured data in data files or front matter.

There are three types of Date and Time inputs:

  • Datetime
  • Date
  • Time

Date and Time input types#

Datetime#

The Datetime input provides an editing interface for date and time values.

You can edit the value of a Datetime input by clicking the date or time text field. Clicking on the date text field will open a calendar for selecting dates.

A screenshot of the Datetime input in the Data Editor shows two text fields for date and time values.
A screenshot of the Datetime input in the Data Editor shows an open calendar widget under the date text field.

The Timezone for your Datetime input appears above the input text field.

Date#

The Date input provides an editing interface for date values only.

You can edit the value of a Date input by clicking the date text field. Clicking on the date text field will open a calendar for selecting dates.

A screenshot of the Date input in the Data Editor shows a text field for a date value.
A screenshot of the Date input in the Data Editor shows an open calendar widget under the date text field.

The Timezone for your Date input appears above the input text field.

Time#

The Time input provides an editing interface for time values only.

You can edit the value of a Datetime input by typing into the time text field.

A screenshot of the Time input in the Data Editor shows a text field for a time value.

Date and Time input appearance and behavior#

You can customize the label, comment, documentation link, and context box for all inputs regardless of type.

A screenshot of the Datetime Input in the Data Editor with a Context Box underneath the text field.

Depending on how your developer configured the input, your Date or Time input may have a different Timezone.

A screenshot of the Datetime Input shows it is using the America/New_York timezone.

Input validation#

Your Date or Time input may also have input validation, which requires the value to match predefined criteria before you can save your changes.

CloudCannon will show a red * next to the name of your Date or Time input if a value is required.

A screenshot of the Datetime input in the Data Editor shows that no value is causing an input validation error.

If you enter a value before the earliest allowed date or after the latest allowed date, CloudCannon will display an error message in red text under the input field.

A screenshot of the Date input in the Data Editor shows that the current value does not meet validation criteria.

For more information on configuration options, valid input values, and unconfigured input behavior, please read our developer documentation on configuring a Date or Time input .

Misconfigured Date and Time inputs#

You will see an orange warning box if your Date or Time input is misconfigured.

A screenshot of a misconfigured Date input in the Data Editor shows an orange warning box.

Date and Time inputs are misconfigured if:

  • The value of a Datetime or Date is not a valid ISO8601 format.
  • The value of a Time input is not a string.

For more information on how to fix a misconfigured Date or Time input, please read our developer documentation on configuring a Date or Time input.

Open in a new tab