> For the complete documentation index, see [llms.txt](https://docs.sprinthub.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.sprinthub.com/en/topics/relate/email/email-marketing-a-b-tests.md).

# Email Marketing - A/B Tests

Find out which emails generate the most engagement with A/B tests, analyzing open and click rates.

## Creating an Automation Flow

In this example, a [automation flow](/en/topics/general/tasks/automation-flows.md) for a [segment](/en/topics/relate/segments.md) with a significant sample of leads, being executed automatically once for each lead in the segment.

<figure><img src="https://684109703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9FzUKkagBNy5uQ7AtGNa%2Fuploads%2FRxTzfynBkDYoGIwnbZtT%2Fimage.png?alt=media&amp;token=aa05ff87-c6e0-4aeb-b707-990e81ecdff1" alt=""><figcaption><p><em>Flow Editing.</em></p></figcaption></figure>

## Alternating Email Sending

When using the block **Switcher**, emails can be distributed among the leads in the segment, dividing them into **Group A** and **Group B**. On each run, the switch directs the lead to one of the two outputs alternately: first to the first output, then to the second, then back to the first, and so on.

<figure><img src="https://684109703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9FzUKkagBNy5uQ7AtGNa%2Fuploads%2FEX1koSG2e7k4w1JPfHeJ%2Fimage.png?alt=media&amp;token=259b33b3-ddcb-44f8-b158-39a37f353102" alt=""><figcaption><p><em>Using the switch block.</em></p></figcaption></figure>

## Checking Lead Behavior&#x20;

After the email sending action, you can first add a **trigger** to check whether the lead opened the email. If so, it is added to a **segment** or **tag**, allowing you to count the number of opens.

Next, it is possible to check whether the lead interacted with the email, using a **trigger** that identifies when they click a link within it. If there is interaction, the lead is also added to a **segment** or **tag**, making it possible to quantify and compare the two tests efficiently.

<figure><img src="https://684109703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9FzUKkagBNy5uQ7AtGNa%2Fuploads%2FyNeXswRhJyaEhqNU8Tpu%2Fimage.png?alt=media&amp;token=5de071a9-f0c8-45ac-a32b-3f550d4d8fdb" alt=""><figcaption><p><em>Triggers and actions to quantify interactions.</em></p></figcaption></figure>

## Conclusion

With this segmentation, it is possible to analyze the difference between open and click rates by observing the number of leads in each segment. In addition, using the function of [Reports](/en/topics/analyze/custom-reports-and-dashboards.md), it is possible to generate custom charts and dashboards, providing a clear view of the results and helping with strategic decision-making based on the tests performed.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://docs.sprinthub.com/en/topics/relate/email/email-marketing-a-b-tests.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
