Examples
A UTC date as ISO 8601 1
A UTC date as ISO 8601 1. This is a constructed public fixture.
Input
01/01/2025 12:34:56Expected answer
2025-01-01T12:34:56Z2025-01-01T12:34:56Z
- Built in formats
Standard date and time- Input format string
DD/MM/YYYY HH:mm:ss- Input timezone
UTC- Output format string
YYYY-MM-DD[T]HH:mm:ss[Z]- Output timezone
UTC
A UTC date as ISO 8601 2
A UTC date as ISO 8601 2. This is a constructed public fixture.
Input
02/01/2025 12:34:56Expected answer
2025-01-02T12:34:56Z2025-01-02T12:34:56Z
- Built in formats
Standard date and time- Input format string
DD/MM/YYYY HH:mm:ss- Input timezone
UTC- Output format string
YYYY-MM-DD[T]HH:mm:ss[Z]- Output timezone
UTC
A UTC date as ISO 8601 3
A UTC date as ISO 8601 3. This is a constructed public fixture.
Input
03/01/2025 12:34:56Expected answer
2025-01-03T12:34:56Z2025-01-03T12:34:56Z
- Built in formats
Standard date and time- Input format string
DD/MM/YYYY HH:mm:ss- Input timezone
UTC- Output format string
YYYY-MM-DD[T]HH:mm:ss[Z]- Output timezone
UTC
A UTC date as ISO 8601 4
A UTC date as ISO 8601 4. This is a constructed public fixture.
Input
04/01/2025 12:34:56Expected answer
2025-01-04T12:34:56Z2025-01-04T12:34:56Z
- Built in formats
Standard date and time- Input format string
DD/MM/YYYY HH:mm:ss- Input timezone
UTC- Output format string
YYYY-MM-DD[T]HH:mm:ss[Z]- Output timezone
UTC
A UTC date as ISO 8601 5
A UTC date as ISO 8601 5. This is a constructed public fixture.
Input
05/01/2025 12:34:56Expected answer
2025-01-05T12:34:56Z2025-01-05T12:34:56Z
- Built in formats
Standard date and time- Input format string
DD/MM/YYYY HH:mm:ss- Input timezone
UTC- Output format string
YYYY-MM-DD[T]HH:mm:ss[Z]- Output timezone
UTC
Translate DateTime Format
Input
01/04/1999 22:33:01Expected answer
Thursday 1st April 1999 22:33:01 +00:00 UTCThursday 1st April 1999 22:33:01 +00:00 UTC
- Built in formats
Standard date and time- Input format string
DD/MM/YYYY HH:mm:ss- Input timezone
UTC- Output format string
dddd Do MMMM YYYY HH:mm:ss Z z- Output timezone
UTC
automatic input format
Input
1999-04-01 22:33:01Expected answer
Thursday 1st April 1999 22:33:01 +00:00 UTCThursday 1st April 1999 22:33:01 +00:00 UTC
- Built in formats
Automatic- Input format string
(empty)- Input timezone
UTC- Output format string
dddd Do MMMM YYYY HH:mm:ss Z z- Output timezone
UTC
invalid input
Input
1234567890Expected rejection
Message matches patternInvalid format.- Built in formats
Standard date and time- Input format string
DD/MM/YYYY HH:mm:ss- Input timezone
UTC- Output format string
dddd Do MMMM YYYY HH:mm:ss Z z- Output timezone
UTC
timezone conversion
Input
01/04/1999 22:33:01Expected answer
Thursday 1st April 1999 17:33:01 -05:00 ESTThursday 1st April 1999 17:33:01 -05:00 EST
- Built in formats
Standard date and time- Input format string
DD/MM/YYYY HH:mm:ss- Input timezone
UTC- Output format string
dddd Do MMMM YYYY HH:mm:ss Z z- Output timezone
US/Eastern
Run with no input to see the relevant format string examples.
Format reference: Translate DateTime Format background and specification