Using Template Variables
A complete reference of all available template variables for emails, SMS, and documents, organised by category with examples and fallback behaviour.
Using Template Variables
Template variables are dynamic placeholders that are automatically replaced with real data when an email, SMS, or document is generated. They allow you to personalise every communication without manual editing. This guide provides a full reference of every available variable.
How Variables Work
Variables use double curly brace syntax: {{variable_name}}. When a message is sent, the system looks up the relevant data and substitutes it in. For example, Hi {{customer_name}} becomes Hi Sarah Johnson.
Customer Variables
| Variable | Description | Example Output |
|---|---|---|
{{customer_name}} | Full name of the customer | Sarah Johnson |
{{customer_email}} | Customer's email address | sarah@example.com |
{{customer_phone}} | Customer's phone number | +44 7700 900123 |
Order Variables
| Variable | Description | Example Output |
|---|---|---|
{{order_number}} | Unique order reference | ORD-2024-001587 |
{{order_total}} | Total order value including tax | £142.50 |
{{order_status}} | Current status of the order | In Production |
{{order_date}} | Date the order was placed | 15 Feb 2026 |
{{order_items}} | Formatted list of items in the order | 2x Widget Housing (PLA, White) |
Business Variables
| Variable | Description | Example Output |
|---|---|---|
{{business_name}} | Your company name | Acme 3D Printing |
{{business_email}} | Your business contact email | hello@acme3d.co.uk |
{{business_phone}} | Your business phone number | 0800 123 4567 |
{{business_address}} | Your full business address | 12 Maker Lane, Manchester, M1 2AB |
Creator / Affiliate Variables
| Variable | Description | Example Output |
|---|---|---|
{{creator_name}} | Name of the referring creator or affiliate | TechReviewer3D |
{{creator_code}} | The affiliate's unique referral code | TECH20 |
Discount Variables
| Variable | Description | Example Output |
|---|---|---|
{{discount_code}} | The discount code applied or generated | WELCOME15 |
{{discount_value}} | Value of the discount (percentage or fixed) | 15% |
Delivery Variables
| Variable | Description | Example Output |
|---|---|---|
{{tracking_number}} | Carrier tracking number | RM1234567890GB |
{{tracking_url}} | Full URL to track the shipment | https://track.carrier.com/RM1234567890GB |
{{delivery_method}} | Selected shipping method | Royal Mail Tracked 24 |
Fallback Behaviour
If a variable has no value available at the time of sending, the system handles it as follows:
- The variable placeholder is replaced with an empty string — it will not display the raw
{{variable_name}}text to the customer. - For critical variables like
{{customer_name}}, consider writing your templates to gracefully handle missing data. For example, use "Hi there" as a fallback greeting rather than relying solely onHi {{customer_name}}. - The
{{order_items}}variable returns a formatted list. If the order has no items (unlikely but possible in edge cases), it will render as empty.
Using Variables in Email vs SMS
Variables work identically in both email and SMS templates. However, keep these differences in mind:
- Email: You have more space, so you can use multiple variables freely. The
{{order_items}}variable works well in emails where a full item list is appropriate. - SMS: Be selective. Each variable's rendered value counts towards your character limit. Stick to essential variables like
{{order_number}}and{{tracking_url}}. Avoid{{order_items}}in SMS as it can produce lengthy output. - Subject lines: Variables can be used in email subject lines. Keep them short —
{{order_number}}works well, but{{order_items}}does not.
Need help with this topic? Contact our support team