Validate Date and Time Input in a SharePoint Text Field
Question details
The user needs to validate a date and time entered in a SharePoint single-line text field.

- Product
- Microsoft SharePoint
- Device & OS
- not provided
- Scenario
- A SharePoint list or library needs to accept dates and times in a format such as dd/mm/yyyy hh:mm.
- Observed behavior
- The input should have the required separators and valid numeric ranges and represent a valid calendar date and time.
Check whether the value must remain text and whether the required format includes seconds. Also check the SharePoint site's regional settings, because they affect how Date and Time values are displayed.
Use a SharePoint Date and Time column
Choose this approach when the value does not have to remain in a text field.
Open the SharePoint list or library, select Add column, and choose Date and time.
Name the column and enable the option to include time, then save the column.
Create or edit an item and enter a date and time. Check the displayed format and review the site's regional settings if the day and month order is not what you need.
If another application requires an exact text string such as dd/mm/yyyy hh:mm, format the Date and Time value in that application or in a separate automation.

Validate the existing SharePoint text field
Use column validation or a custom form when the date and time must remain text.
Work with Office files in WPS Office
WPS Office is a free, lightweight alternative for working with Office files in a familiar interface. Its format compatibility can help you move existing documents and spreadsheets with less disruption; it does not configure SharePoint field validation.

Frequently Asked Questions
Why use a Date and Time column instead of a text field?
A SharePoint Date and Time column accepts date and time values rather than arbitrary text, avoiding the need to build all date-validation checks yourself. Select Add column > Date and time to create one.
Will a Date and Time column always display dd/mm/yyyy hh:mm?
Not necessarily. Display depends on regional settings and the SharePoint interface. If an exact text format is required, format the value in the consuming application or an automation.
Can I validate an existing single-line text column?
Yes. Open the column settings and use Column validation to add a formula and error message. The formula must check both the text pattern and whether the date and time are valid.
How can I validate text if the SharePoint formula is too complex?
Where available, select Integrate > Power Apps > Customize forms and add validation before saving. Also validate any entries that bypass the custom form.




