Skip to content

The open alternative to Salesforce, designed for AI.

5.2 KB
Raw Blame
---
title: Send Emails from Workflows
description: Send personalized emails automatically using workflow actions.
---

import { PageBanner } from "/snippets/page-banner.mdx"

## Prerequisites

Before you can send emails from workflows:
1. Connect an email account under **Settings → Accounts**
2. Ensure the account has sending permissions enabled

## Basic Email Workflow

### Example: Welcome Email for New Contacts

**Goal**: Send a welcome email when a new person is added to the CRM.

**Setup**:

1. **Create workflow**: Go to **Settings → Workflows** and click **+ New Workflow**

2. **Add trigger**: Select **Record is Created** → **People**

3. **Add Send Email action**:
   - Click **+** to add an action
   - Select **Send Email**
   - Configure the email:

| Field | Value |
|-------|-------|
| **To** | `{{trigger.properties.after.emails.primaryEmail}}` |
| **Subject** | `Welcome to {{Your Company Name}}` |
| **Body** | `Hi {{trigger.properties.after.name.firstName}}, ...` |

4. **Test and activate**: Test with a sample record, then activate

## Using Variables in Emails

Reference data from previous steps using `{{variable}}` syntax:

```text
Hi {{trigger.properties.after.name.firstName}},

Thank you for connecting with us!

Best regards,
The Team
```

### Available Variables from Triggers

| Trigger Type | Common Variables |
|--------------|------------------|
| **Record Created/Updated** | `{{trigger.properties.after.fieldName}}` |
| **Record Deleted** | `{{trigger.properties.before.fieldName}}` |
| **Manual** (on a selected record) | `{{trigger.payload.fieldName}}` |
| **Webhook** | `{{trigger.fieldName}}` |

Relation fields only expose the related record's ID, for example `{{trigger.properties.after.companyId}}`. To use other fields of the related record, add a **Search Records** step first. The easiest way to get the right path is to insert the variable from the picker.

## Advanced: Conditional Emails

### Example: Different Emails Based on Lead Source

**Goal**: Send different welcome emails based on where the lead came from.

**Setup**:

1. **Trigger**: Record is Created (People)

2. **Add Filter action**:
   - Condition: `{{trigger.properties.after.source}}` equals `"Website"`
   - If true → continue to website welcome email

3. **Branch for other sources**:
   - Create parallel branches for different sources
   - Each branch has its own Send Email action

## Sending Emails to Multiple Recipients

### Example: Notify Team When Deal Closes

**Goal**: Email the sales rep and their manager when an opportunity is won.

**Setup**:

1. **Trigger**: Record is Updated (Opportunities, Stage = "Closed Won")

2. **Search Records** (name it "Find Owner"): Find the opportunity owner
   - Object: Workspace Members
   - Filter: ID equals `{{trigger.properties.after.ownerId}}`

3. **Search Records**: Find the opportunity owner's manager

4. **Send Email #1**: To opportunity owner
   - To: `{{Find Owner.first.userEmail}}` (select it from the variable picker; typing the step name does not work)
   - Subject: `Congratulations on closing {{trigger.properties.after.name}}!`

5. **Send Email #2**: To manager
   - To: `{{searchRecords.manager.email}}`
   - Subject: `Deal Won: {{trigger.properties.after.name}}`

## Scheduled Follow-up Emails

### Example: Follow Up 3 Days After Meeting

**Goal**: Send a follow-up email 3 days after a meeting is logged.

**Setup**:

1. **Trigger**: Record is Created (Activities, Type = "Meeting")

2. **Delay action**: Wait 3 days

3. **Send Email**:
   - To: Meeting attendee
   - Subject: Following up on our conversation
   - Body: Reference meeting details from trigger

## Email Attachments

You can attach files to emails sent from workflows. The attachment is a static file that you upload when configuring the workflow.

### How to Add an Attachment

1. In the **Send Email** action, click on the **Attachments** button
2. Click to upload a file from your computer
3. The file will be attached to all emails sent by this action

### Common Use Cases

| Use Case | Example File |
|----------|--------------|
| **Welcome emails** | Company brochure (PDF) |
| **Onboarding sequences** | Getting started guide |
| **Sales follow-ups** | Product catalog or price list |
| **Event confirmations** | Event details or agenda |

<Note>
Attachments are static—the same file is sent to all recipients. For dynamic documents (like personalized quotes), generate and attach files using a [Logic Function](/user-guide/workflows/how-tos/connect-to-other-tools/generate-pdf-from-twenty).
</Note>

## Best Practices

### Email Content
- Keep subject lines concise and relevant
- Personalize with recipient's name
- Include a clear call to action
- Test emails before activating

### Deliverability
- Don't send too many emails too quickly
- Use professional email signatures
- Avoid spam trigger words
- Ensure unsubscribe options for marketing emails

### Troubleshooting
- Verify email account is connected and active
- Check recipient email address is valid
- Review workflow runs for error messages
- Test with your own email address first

## Related

- [Workflow Triggers](/user-guide/workflows/capabilities/workflow-triggers)
- [Workflow Actions](/user-guide/workflows/capabilities/workflow-actions)

<PageBanner illustration="page-cover-email" />