Messaging & Communication / Email
How do I edit email templates?
Published 28. sep. 2026, 16.03
TL;DR
Build and modify email templates with the Hubhus template editor - preview with real lead data, search placeholders with CTRL+K, add conditional logic with @if, and test before activating.
Get started in 4 steps
- Go to Campaign settings → Emails → New Email Template. Set a name, sender details, and subject line. Click Edit to open the template editor.
- Write your email body. Use CTRL+K / CMD+K to search and insert placeholders - lead data, event info, assigned person, checklists, files, and more.
- Add dynamic logic with
@ifwhere needed (e.g. show different text based on postal code, lead type, or assigned person). Optional: apply a layout for consistent branding. - Test with a real lead using the preview in the editor. Send a test email and verify the output. Then activate the template in your automation or action listener.
%lead_email% or %assigned_person_email% ·
Deep guide: Working with the template editor
Read more
@if / @else logic - Hubhus syntax
@if(%assigned_person_email%){
Your consultant: %assigned_person_name%
}@else{
Contact us at support@yourcompany.com
}@endif
Supported operators: == != ~= (contains, case-insensitive) >= <= > <
Logical: || and && - note: || is evaluated before &&. Parentheses are not supported.
Recipient fields and conditional sending
All recipient fields (To, CC, BCC, From, Reply-to) support dynamic placeholders and @if logic. Example with fallback:
@if(%assigned_person_email%){
%assigned_person_email%
}@else{
%brand_contact_email%
}@endif
Conditional send requirement: the template only sends if this evaluates to truthy:
@if(%lead_postal_code% == 2000){1}@endif
Spam protection rules
Each template has configurable limits: max emails per lead, max per email address, blacklist/whitelist campaigns, frequency limits (e.g. max 1 per hour), and unsubscribe handling. If emails aren't sending, always check these rules first.
HTML email best practices
- Use
<table>-based layout - most email clients require it - Keep all styles inline
- Use absolute URLs for images
- Close all tags
- Avoid flexbox, grid, external stylesheets, and JavaScript
- Use Hubhus HTML components for reusable headers/footers