Skip to content

HTML templates

A template is everything Frontmail needs to turn a set of params into a finished email. You edit it in Templates in the dashboard; every save creates a new version.

Part Notes
Name, description, locale Locale (en / cs) drives formatDate, formatNumber and formatMoney output.
Subject May contain params: Order {{order_id}} confirmed.
To, CC, BCC Comma-separated addresses. Params allowed only with Allow dynamic recipient (see below). Max 50 recipients in total.
From name, From email From email must be allowed by the connected service (verified domain or sender).
Reply-To Commonly {{email}} so you can reply to the visitor directly.
HTML body A complete HTML document including <head> and <style>.
Text version Generated from the HTML automatically; switch off auto to edit it by hand.
Parameters The typed schema – see Parameters and types.
Service & fallback service Which service sends it, and which takes over on failure.
Security CAPTCHA required (default on when your organization has Turnstile keys, otherwise off; a file’s explicit false is kept), Allow dynamic recipient (default off).
Attachments Static files, dynamic attachments on/off, inline images – see Attachments.
Auto-reply, contact collection See Auto-reply and Contact collection.

The editor is split in two:

  • Left: HTML code editor with Handlebars highlighting and autocomplete for your params (type {{ to see them). A visual editor is available for simple templates; you can switch to HTML at any time.
  • Right: live preview in a sandboxed iframe. Toggle desktop / mobile width, light / dark background and HTML / plain-text version. The preview re-renders as you type.

Below the preview is the params panel – a form generated from the schema where you edit the sample values used by the preview and by test sends.

Many email clients (notably Gmail on some platforms and Outlook) ignore <style> blocks. With Inline CSS on save turned on, Frontmail copies your rules into style="" attributes when you save, and keeps media queries in <style> for clients that support them.

The checks panel runs on every change and warns about:

  • missing params – used in the template but not defined in the schema,
  • unused params – defined but never used,
  • invalid Handlebars – unclosed blocks, unknown helpers (only the built-in helpers are available),
  • images without alt – bad for accessibility and for clients that block images,
  • size over ~100 kB – Gmail clips messages larger than about 102 kB and hides the rest behind “View entire message”.

Warnings never block saving, but a template that fails to compile cannot be sent.

By default To, CC and BCC must be fixed addresses. If a recipient field contains a param (for example To: {{email}}), sends are rejected with dynamic_recipient_not_allowed unless you enable Allow dynamic recipient on the template.

With the public key, a template with a dynamic recipient is sent only with a locked content: CAPTCHA required, fixed sender fields, no HTML params, texts up to 500 characters, links only to allowed domains and at most 5 emails per recipient per day.

For the common “thank the visitor” case, use an auto-reply instead.

Emails sent on the Free plan get a small “Sent via Frontmail” footer. Paid plans have no footer.

  • Import: paste HTML or upload an .html file; Frontmail detects params from {{…}} placeholders.
  • Export: download the template (HTML, text, settings and param schema) as JSON, e.g. to move it to another organization.