Appearance
Date Functions
Date functions format and generate date/time values. Dates are handled as strings in PHP date format.
date_format
Formats a date string using a PHP date format.
Signature: date_format(date, format?)
| Parameter | Type | Default | Description |
|---|---|---|---|
date | string | -- | The date string to format. Accepts most date formats (YYYY-MM-DD, YYYY-MM-DD HH:MM:SS, timestamps, relative strings). |
format | string | Y-m-d | PHP date format string. |
`{ {date_format(row.created_at, 'F j, Y')}}`
// "2025-03-15 14:30:00" → "March 15, 2025"
`{ {date_format(row.event_date, 'm/d/Y')}}`
// "2025-03-15" → "03/15/2025"
`{ {date_format(row.updated_at, 'M j, g:i A')}}`
// "2025-03-15 14:30:00" → "Mar 15, 2:30 PM"If the input date cannot be parsed, the current time is used as a fallback.
Common Format Strings
| Format | Example Output |
|---|---|
Y-m-d | 2025-03-15 |
F j, Y | March 15, 2025 |
m/d/Y | 03/15/2025 |
d.m.Y | 15.03.2025 |
D, M j | Sat, Mar 15 |
l, F j, Y | Saturday, March 15, 2025 |
g:i A | 2:30 PM |
H:i | 14:30 |
M j, Y g:i A | Mar 15, 2025 2:30 PM |
Y-m-d\TH:i:s | 2025-03-15T14:30:00 (ISO 8601) |
PHP Format Tokens
| Token | Description | Example |
|---|---|---|
Y | 4-digit year | 2025 |
y | 2-digit year | 25 |
F | Full month name | March |
M | Short month name | Mar |
m | Month (zero-padded) | 03 |
n | Month (no padding) | 3 |
d | Day (zero-padded) | 05 |
j | Day (no padding) | 5 |
l | Full day name | Saturday |
D | Short day name | Sat |
H | Hour 24h (zero-padded) | 14 |
h | Hour 12h (zero-padded) | 02 |
g | Hour 12h (no padding) | 2 |
i | Minutes | 30 |
s | Seconds | 00 |
A | AM/PM | PM |
a | am/pm | pm |
now
Returns the current date and time in Y-m-d H:i:s format (UTC).
Signature: now()
`{ {now()}}`
// "2025-03-15 14:30:00"Commonly used in pipeline Set Field nodes:
fieldName: "created_at"
expression: "now()"today
Returns the current date in Y-m-d format (UTC).
Signature: today()
`{ {today()}}`
// "2025-03-15"Useful for filtering:
row.event_date == today()Examples
Display "time ago" style text (approximation)
Posted on `{ {date_format(row.created_at, 'M j, Y')}}`Set timestamp on form submission
In a Set Field node:
fieldName: "submitted_at"
expression: "now()"Compare dates in conditions
row.expires_at < today()
// true if the expiry date is in the pastFormat for different regions
// US format
`{ {date_format(row.date, 'm/d/Y')}}`
// European format
`{ {date_format(row.date, 'd.m.Y')}}`
// ISO format
`{ {date_format(row.date, 'Y-m-d')}}`