Built-in variables
These variables are available in the Variable dropdown for the "Variable comparison" condition type. All date/time values use your WordPress timezone (Settings → General).
Date and time
| Variable | Type | Example | Description |
now | text | 2026-05-06 14:30:00 | Current date and time |
current_date | text | 2026-05-06 | Current date |
current_hour | number | 14 | Current hour, 0–23 |
current_day | number | 3 | Day of the week: 1=Monday … 7=Sunday |
current_month | number | 5 | Month: 1–12 |
current_year | number | 2026 | Current year |
Post
| Variable | Type | Example | Description |
ID | number | 42 | Current post ID |
post_status | text | publish | Post status |
post_type | text | post | Post type |
post_author | text | admin | Author username |
post_author_id | number | 1 | Author user ID |
comment_count | number | 12 | Number of comments |
content_length | number | 3420 | Content length in characters (no HTML) |
excerpt_length | number | 280 | Excerpt length in characters |
post_age_days | number | 45 | Days since the post was published |
post_has_thumbnail | text | true | Whether the post has a featured image |
post_word_count | number | 820 | Word count of the post content |
User
| Variable | Type | Example | Description |
user_id | number | 5 | Current user ID (0 if not logged in) |
user_role | text | subscriber | First role of the current user |
is_logged_in | text | true | Whether the user is logged in |
WooCommerce
Available only when WooCommerce is installed and active.
| Variable | Type | Example | Description |
cart_count | number | 3 | Number of items in the cart |
cart_total | number | 149.90 | Cart subtotal (before shipping and tax) |
UTM / Campaign parameters
| Variable | URL parameter | Example value |
utm_source | ?utm_source=newsletter | newsletter |
utm_medium | ?utm_medium=email | email |
utm_campaign | ?utm_campaign=black_friday | black_friday |
utm_content | ?utm_content=banner_top | banner_top |
utm_term | ?utm_term=elementor | elementor |
UTM variables are empty when the parameter is not present in the URL.