•••
 
Documentation   /   Reference: syntax   /   Date formats
 
 

Date formats

 

Date formats are used by [[DATE]], by [[MATH=date_format:...]] and by the ---format directive on date fields.

Named formats

Format Example output
ISO 8601 2027-01-05T09:30:00Z
RFC 2822 Tue, 05 Jan 2027 09:30:00 +0000
UNIX 1799141400 (a Unix timestamp)

Building your own

Token Output Example
D Day of the month 5
DD Day of the month, two digits 05
MM Month number, two digits 01
MMM Short month name Jan
MMMM Full month name January
YY Two-digit year 27
YYYY Four-digit year 2027

Separate tokens with spaces, /, -, . or ,. Tokens aren't case-sensitive.

Format Output
D MMMM YYYY (default) 5 January 2027
DD/MM/YYYY 05/01/2027
YYYY-MM-DD 2027-01-05
MMM YY Jan 27
Important

Use only the tokens and separators above. Other letters in a format can be read as formatting codes and produce unexpected output.