> For the complete documentation index, see [llms.txt](https://doc.orbeon.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://doc.orbeon.com/form-runner/api/data-formats/date-and-time.md).

# Date and time

## Introduction

There are two perspectives on dates and times with Orbeon Forms:

* the perspective of the user of the form, where those are human-readable
* the perspective of the data storage, where those are stored in a standard, human-language-independent format

In this page we discuss dates and times from the perspective of the data.

## Basic format

When using XML, date and time formats usually follow the formats defined in XML Schema, which are a subset of ISO 8601 formats. Specifically, the formats for date, time, and dateTime are specified here:

* [date](http://www.w3.org/TR/xmlschema-2/#date)
* [time](http://www.w3.org/TR/xmlschema-2/#time)
* [dateTime](http://www.w3.org/TR/xmlschema-2/#dateTime)

In practice, the base format is pretty simple, for example:

* `date`: `2012-09-17`
* `time`: `17:24:00`
* `dateTime`: `2012-09-17T17:24:00`

All fields have a fixed number of digits.

## Fractional seconds

In addition, you can add any fractional seconds to the time:

* `2012-09-17T17:24:00.1234`

## Timezones

Things get a bit more complicated if you add optional timezone information. You can have things like:

* `2012-09-17T17:24:00Z` (which means UTC time)
* `2012-09-17T17:24:00+05:00` (timezone indicated with an offset)

For a full reference, the XML Schema documentation linked above is the reference, as Orbeon Forms follows that specification.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://doc.orbeon.com/form-runner/api/data-formats/date-and-time.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
