---
title: "Marketing emails with unsubscribe links from Shopify Flow"
description: "Mark a layout as marketing, send it with the Send Marketing Email action, and let the app add the unsubscribe link, your company details and the unsubscribe list for you."
canonical: "https://docs.workflow-transactional-email.app/marketing-emails"
---

# Marketing emails and unsubscribes

Some emails a customer expects: an order confirmation, a shipping update, a password reset. Others they may not want: a newsletter, a review request, a win-back offer. A layout now says which of the two it is. A **marketing** layout gets what mail providers and anti-spam laws expect from marketing email: an unsubscribe link in every message, your company details in the footer, and a list of customers who opted out that the app honours on its own. **Transactional** emails do not change at all.

## Transactional or marketing: the Email type

When you create a layout, the create page asks for its **Email type**:

| Email type | What it is for | What the app does |
| --- | --- | --- |
| **Transactional** | Emails customers expect, like order and shipping updates | Sent as before: one email to every recipient, always, even to customers who unsubscribed from marketing |
| **Marketing** | Newsletters, promotions, review requests, win-back emails | One email per recipient with an unsubscribe link and your company details in the footer; customers who unsubscribed are skipped |

**Transactional is the default**, and every layout you made before this release is transactional. Nothing you have today sends differently.

You can change the type later. On a rich text / HTML layout the **Email type** field sits in **Basic information**; in the visual builder it is on the **General** tab. On a translation it is read-only, because the type belongs to the layout and is shared by all its languages.

The **Email Layouts** list has two tabs, **Transactional** and **Marketing**, each with its count. Marketing layouts also carry a **Marketing** badge next to their name, and a layout created from the Marketing tab starts with **Marketing** selected.

## The Flow action: Send Marketing Email

The app adds a third action to Shopify Flow. **Send Marketing Email** sends marketing layouts; **Send Transactional Email** keeps sending transactional ones.

The fields are the same in both actions: **To Email(s)**, **CC Email(s)**, **BCC Email(s)**, **Reply-To**, **From name**, **Language** and **Variables (JSON)**. Everything on [Passing data from Shopify Flow](https://docs.workflow-transactional-email.app/passing-data-from-shopify-flow.md), [Send emails in your customer's language](https://docs.workflow-transactional-email.app/layout-languages.md) and [Reply-To and From name](https://docs.workflow-transactional-email.app/reply-to-and-from-name.md) applies to both.

On the action's configuration screen you pick the sender under **Send from** and the layout under **Layout**. In Send Marketing Email **only marketing layouts are listed**; in Send Transactional Email only transactional ones. If you have no marketing layout yet, the screen says so: create one in the app, or set an existing layout's Email type to Marketing, then come back.

### When the layout and the action do not match

A step is checked when you save the workflow. A Send Marketing Email step that points at a transactional layout shows the error **This step needs a marketing layout. Pick one, or set the layout's email type to Marketing.** The other way round, Send Transactional Email says the same about a transactional layout.

If a mismatch slips through anyway (you changed a layout's type after the step was built), this is what happens when the step runs:

- **Send Marketing Email with a transactional layout**: nothing is sent. History shows a **Failed** event with that message and no action is used from your plan.
- **Send Transactional Email with a marketing layout**: the email is sent as a marketing email, with the unsubscribe link, the footer and the unsubscribe list. The layout decides how an email goes out.

### What the action returns

Later Flow steps can branch on the result:

| Return field | Values |
| --- | --- |
| `status` | `SENT`, `FAILED` or `SKIPPED` (every recipient had unsubscribed) |
| `messageId` | The provider's message id of the first email sent, when available |
| `provider` | `GOOGLE`, `MICROSOFT`, `SMTP` or `DEFAULT` |

> [!WARNING]
> **Send Marketing Email is a new step type, not a change to the existing one.** Your Send Transactional Email steps and the workflows around them are untouched and keep running exactly as before. To send a marketing layout, add a **Send Marketing Email** step to the workflow and pick the sender and the layout there.

## How a marketing email is sent

A transactional email is one message to everybody on the To line. A marketing email works differently, because every recipient needs their own way out:

- **One email per To recipient.** Each recipient gets their own message with their own unsubscribe link and their own unsubscribe headers, so nobody can unsubscribe somebody else.
- **CC and BCC go on every message**, both the step's own and the shop defaults from Settings.
- **Unsubscribed recipients are removed first**, from To, CC and BCC.
- **At most 20 To recipients per action.** Recipients beyond the 20th are not sent to; History records them as *Not sent: more than 20 recipients in one action*. For a bigger audience, let Shopify Flow run the step once per customer, or split the list across steps.
- The messages go out one after another, within the rate limit of the sender you picked.

**One action is one History entry and one action against your plan**, however many recipients it had. The History entry lists every recipient with its outcome: sent, failed or skipped, with the reason.

| Result | When | Status in History |
| --- | --- | --- |
| Everyone got their email | | **Success** |
| Some got it, some did not | A recipient failed after another had been sent | **Failed**, the error message names who was left out. Flow does not retry, because a retry would send again to the ones already served |
| Nobody got it, temporary problem | The sender said "try later" on the first message, or its rate limit stayed full | Shopify Flow retries the whole step later, as with a transactional email |
| Every To recipient had unsubscribed | | **Skipped**, nothing is sent, see below |

## The unsubscribe footer

Every marketing email ends with a small footer below your layout: the **unsubscribe sentence** with the link in it, and your **company details**. It is added automatically; you do not have to put anything into the layout.

Out of the box the sentence is *You receive this email because you are a customer of our store.* followed by a link labelled **Unsubscribe**, and the company details are empty. Fill them in before you send your first marketing email.

### Edit the texts in Settings

Under **Settings**, tab **Marketing emails**, you find three fields:

| Field | What it is |
| --- | --- |
| **Unsubscribe sentence** | The sentence at the end of the email. Put `{{ unsubscribe_link }}` where the link goes, or `{{ unsubscribe_url }}` for the bare address |
| **Unsubscribe link text** | The text of the `{{ unsubscribe_link }}` link |
| **Company details** | Your business name and postal address, for example *My Store Ltd, 1 Main Street, 10115 Berlin, Germany* |

Below them, **Languages** lets you add the same three fields per language. An email sent in one of those languages (through the Flow step's **Language** field or the layout's main language) uses its texts; every other email uses the main texts above. An empty field in a language uses the main text for that field. The **Preview** at the bottom shows the footer exactly as it is sent, per language.

### Override them per layout or per language

A marketing layout has a **Marketing footer** card (in the page of a rich text / HTML layout, on the **General** tab of the visual builder). Under **Footer texts** choose:

- **Use the texts from Settings**: the default. Change them under Settings, Marketing emails.
- **Custom texts for this layout**: the three fields appear, prefilled with what is sent today. Only emails from this layout use them, and an empty field falls back to Settings.

A translation of the layout has the same card with **Same as the layout** or **Custom texts for this language**. An empty field there falls back to the layout's texts.

So for every field, the app takes the first one that is set: the translation's text, then the layout's, then the Settings text for the email's language, then the main Settings text, then the app default. Custom footer texts travel with the layout: they are part of its version history, its duplicates, its exports and the API.

### Place the link yourself

You can put the link anywhere in a marketing layout instead of leaving it to the footer, for example in your own footer preset or an HTML block:

- `{{ unsubscribe_link }}` renders a link with your **Unsubscribe link text**.
- `{{ unsubscribe_url }}` renders the bare address, for a button or your own anchor.

When the rendered email already contains the link, the footer leaves the unsubscribe sentence out and appends only the company details. Both variables render as nothing in the subject and the preview text, and as nothing in a transactional layout.

### The sentence must carry the link

An unsubscribe sentence without `{{ unsubscribe_link }}` or `{{ unsubscribe_url }}` cannot be saved, in Settings, in the layout editors or over the API: *The unsubscribe sentence must contain  or , so every marketing email has a way out.* Leaving the field empty is fine; the inherited sentence is used.

> [!WARNING]
> **This is not legal advice.** Whether you may send a marketing email to a customer, and what consent you need for it, is your responsibility. The app gives every marketing email a working unsubscribe link and honours the list, and it expects your **Company details** to hold your business name and postal address, because most anti-spam laws (CAN-SPAM in the US, the ePrivacy rules and GDPR in the EU, and others) require marketing email to show who sends it. Check the rules that apply to your store and your customers.

## What the customer sees

**The link in the email** opens a small confirmation page in the language the email was sent in. It shows your store name (the first line of your company details, otherwise your store's handle), the address in masked form (`j***@example.com`) and an **Unsubscribe** button. Only the button unsubscribes: opening the link alone changes nothing, so a link scanner or a preview in a mail client cannot unsubscribe anyone. After the click the page says **You are unsubscribed**, with a **Subscribe again** link to undo it. The page also tells the customer that they will keep receiving emails about their orders.

**The unsubscribe button of the mail client.** Emails sent through an **SMTP server** or a **Google** sender carry the `List-Unsubscribe` and `List-Unsubscribe-Post` headers, so Gmail, Apple Mail and other clients can show their own one-click unsubscribe button. That button records the unsubscribe without opening a page. **Microsoft 365** senders cannot set these headers, so there is no button in the mail client for them; the link in the footer works the same way.

**Test emails.** A test email from the layout editor also carries the footer, but its link opens a page saying **This is a test email**, and nothing is changed. A test email is never skipped, even if the test address is on your unsubscribe list.

## After an unsubscribe

From the next send on, the address is left out of every marketing email. Upper and lower case do not matter.

- If **other To recipients remain**, they get their emails as usual. The History entry notes how many recipients were left out.
- If **every To recipient has unsubscribed**, nothing is sent. History shows the event as **Skipped (unsubscribed)** with an explanation instead of an error, the Flow step returns `status: SKIPPED`, and no action is used from your plan. It does not count as a failure either, so it never trips the failure-rate alert. A Skipped event has no **Resend** button, because there is nothing to resend.
- **Transactional emails are not affected.** An order confirmation still reaches a customer who unsubscribed from marketing.
- **Resend** from History on a marketing email is a real send: it checks the unsubscribe list again, and refuses when every recipient has unsubscribed since.

## The Unsubscribes page

**Unsubscribes** in the app's navigation lists everyone who opted out. Customers on this list no longer receive emails from your marketing layouts; transactional emails still reach them.

| Column | Contents |
| --- | --- |
| **Email address** | The address, in full |
| **Unsubscribed on** | Date and time |
| **Layout** | The marketing layout whose link was used, when known |
| **Source** | **Unsubscribe link** (the customer clicked, in the email or in the mail client) or **Added by you** |

What you can do there:

- **Search** for a full email address or part of a layout name.
- **Add address** puts an address on the list by hand, for a customer who asked you directly.
- **Resubscribe** removes an address from the list again. The dialog reminds you to do this only when the customer asked for it.
- **Export CSV** downloads the whole list with the columns `email`, `unsubscribed_at`, `layout`, `reason` and `language`.

The **Sending health** card on the dashboard shows how many customers unsubscribed in the last 30 days, with a link to the page. See [Sending health](https://docs.workflow-transactional-email.app/sending-health.md).

The list is stored in a way that protects the addresses: a hash for matching and the address itself encrypted. It is deleted when you uninstall the app, and a customer's entry is deleted when Shopify sends a data erasure request for that customer. See [Data, privacy and security](https://docs.workflow-transactional-email.app/data-privacy-and-security.md).

## Through the API

A layout's `category` (`transactional` or `marketing`) and its custom footer texts (`marketingTexts`) can be read and written over the REST API and the MCP tools, on the layout and on each translation. See [REST API reference](https://docs.workflow-transactional-email.app/developer-rest-api.md) and [Connect an AI assistant (MCP)](https://docs.workflow-transactional-email.app/developer-mcp.md).

## Related

- [Build an email layout](https://docs.workflow-transactional-email.app/build-an-email-layout.md) - layouts, the visual builder and rich text / HTML.
- [Send emails in your customer's language](https://docs.workflow-transactional-email.app/layout-languages.md) - translations, and the Language field that also picks the footer texts.
- [Settings](https://docs.workflow-transactional-email.app/settings.md) - email defaults, the marketing footer texts and brand colors.
- [Email deliverability](https://docs.workflow-transactional-email.app/email-deliverability.md) - why marketing email needs a clean sender and a real address.
- [History and troubleshooting](https://docs.workflow-transactional-email.app/history-and-troubleshooting.md) - what History records for every recipient.
