# Email Templates

Email templates are the design and structure of your emails. In UbiQuity, templates are built using EasyEdit - a template system that lets you create professional, responsive emails by adding and editing article blocks without writing code.

If you have a web designer or developer, they can also write custom HTML for a template directly.

EasyEdit templates are optimised for desktop, tablet, and mobile by default. They can be built with colour selectors, font settings, logo areas, and customisable content blocks - similar to a CMS.

UbiQuity can build a custom EasyEdit template for your account. Contact UbiQuity to discuss your requirements.

***

### To and Reply fields

The header section of your email template is where you set the sender details and subject line.

| Field       | Description                                                                                                              |
| ----------- | ------------------------------------------------------------------------------------------------------------------------ |
| From Email  | The email address the email appears to come from. Contact UbiQuity to set up a custom From Address.                      |
| From Name   | The friendly name shown in the recipient's inbox, e.g. *UbiQuity Marketing*.                                             |
| Reply Email | Where replies are sent if the recipient clicks Reply, e.g. [*marketing@example.com*](mailto:marketing@example.com).      |
| Reply Name  | The friendly name shown when the recipient clicks Reply.                                                                 |
| Subject     | The subject line of the email.                                                                                           |
| Pre-header  | Preview text that appears before the email is opened. Well-written pre-header text can significantly improve open rates. |

<figure><img src="/files/HCeZx2HDbGPI4ZOE93to" alt="A screenshot of the header options available in each Email Templates"><figcaption><p>The header options available in each Email Templates</p></figcaption></figure>

***

### Merging fields

Merge fields let you personalise email content with data from your UbiQuity database. Wherever you see the **Insert Merge Field** icon in the content editor, you can merge in a field.

Click **Insert Merge Field** to open the Merge Field Selector. Expand the relevant node to find the field you want, then click **Add** to insert it. Merged fields appear as `[Database.Field Name]` in the editor.

Use the **Preview** button to test how merge fields appear for a specific contact. If a contact has no value for a merged field, the field returns blank. To handle this gracefully - for example showing *"Hi there"* instead of *"Hi "* - you can use an IF statement in ESL (Engage Scripting Language).

If you are adding merge fields to a triggered email (from a Form, Survey, or Event) rather than a mailout, you can merge in fields specific to that Form, Survey, or Event rather than database fields.

<figure><img src="/files/h45vO5hjlYXlrukU1G2X" alt="A screenshot of the Insert Merge Field icon shown next to fields such as Subject."><figcaption><p>The Insert Merge Field icon shown next to fields such as Subject.</p></figcaption></figure>

<figure><img src="/files/MYqggmY5iMoChT9mAH8r" alt="A screenshot of the Insert Merge Field button in the content editor."><figcaption><p>The Insert Merge Field button in the content editor.</p></figcaption></figure>

***

### Insert UbiQuity Link

Use the **Insert UbiQuity Link** function to insert a link to a UbiQuity Form, Survey, or Event into your email template.

<figure><img src="/files/c0QZWM2X8xdxB38NKaJh" alt="A screenshot of the Insert Merge Field button in the content editor."><figcaption><p>The Insert UbiQuity Link button in the content editor.</p></figcaption></figure>

***

### Opt Out Link

Every email template must contain a link to a Form that includes your database Opt Out field. This is required before you can send a mailout. UbiQuity will set this up automatically in most cases - if it does not, you will need to:

1. Create an Update Web Form
2. Click **Edit Fields and Validation**
3. Add the **Opted Out** field
4. Save the form
5. Use the **Insert Link** function in your template to add the opt-out link

When the mailout is sent, recipients can click the link to set their Opted Out field to Yes. They will automatically be excluded from future mailouts.

If you are sending to a group that does not require opt-out management, this requirement can be turned off - contact UbiQuity to arrange this.

***

### Article filters

Each article block in an email template can have a filter applied to control its visibility. This lets you show different content to different contacts within a single email, without needing to set up separate mailouts.

Click **Edit article** and expand the filter section to apply filters. Article filters can be based on database fields, transactional data, and other contact interactions in UbiQuity.

<div align="center"><figure><img src="/files/l30fZdODiwFbWUSmAjIP" alt="A screenshot of Article Filters which can be used to control who can see specific articles."><figcaption><p>Use Article Filters to control who can see specific articles.</p></figcaption></figure></div>

***

### Images and PDFs

The Media Manager is available wherever you can add or edit content. Use it to insert images and link to PDFs or other documents.

To upload files, click the tile or drag files onto it. You can upload multiple files at once.

To resize an image after inserting it, right-click the image and select **Image Properties**.

Keep image file sizes below 200KB where possible, and no larger than 500KB. Large images are slow to render and can affect the email experience.

***

### Attaching files

Attaching files directly to emails is generally not recommended - attachments can be stripped by corporate firewalls, add significant bandwidth, and cannot be reported on in UbiQuity.

The preferred approach is to upload the file to the Media Manager and insert it as a link. The file is only downloaded when the recipient clicks the link, which is faster and trackable.

#### Personalised attachments

UbiQuity supports personalised attachments - unique files attached to each individual email. This is useful for sending personalised quotes, invoices, tax receipts, or statements.

Personalised attachments must be enabled on your account by UbiQuity before use. UbiQuity does not generate the files itself - the documents must be hosted at an external URL, and UbiQuity calls that URL with the relevant merge fields to retrieve the correct file for each contact.

| Field                   | Description                                                                                                                                                                         |
| ----------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Description             | A label used within UbiQuity to identify the attachment type, e.g. *Tax Receipt*.                                                                                                   |
| Attachment URL          | The URL where the attachment is hosted, with merge fields to identify the correct file per contact. For example: `https://example.com/id=[Database.ID].pdf`                         |
| Friendly Filename       | The name the file will be given when attached to the email, e.g. *Tax Receipt for \[Database.First Name]*. Do not include the file extension — this is pulled from the file itself. |
| Send Without Attachment | If checked, the email will send even if no attachment is found for a contact. If unchecked, emails without a valid attachment will not send.                                        |

***

### Previewing a template

Use the preview function to see how merge fields will appear for a specific database contact. You can select multiple contacts and send preview emails to your inbox - one email per selected contact.

An address book is available if you preview frequently.

***

### Text and HTML versions

Every email is made up of two parts: an HTML version (with images, fonts, and formatting) and a plain text version. Some older email clients cannot display HTML and will show the text version instead.

UbiQuity automatically adds a View Online link to the text version, so recipients using a text-only client can click through to the HTML version in their browser. You generally do not need to edit the text version, but you can update it using the tabs in the editor.

***

### [Default Template](/documentation/channels/email/email-templates/default-template.md)

Every UbiQuity account comes with a default email template - a base EasyEdit template that is pre-configured and ready to use. The following pages document this default template in detail.

* [Default Template](/documentation/channels/email/email-templates/default-template.md) - introduction to the default template
* Field Types - The field types available when editing your template
* Base Settings - Template-wide settings for fonts, colours, and layout
* Article Blocks - How to add, edit, and manage article blocks
* Layout Breakdown - Detailed guide to each of the nine article layouts


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.ubiquity.co.nz/documentation/channels/email/email-templates.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
