# ABx Test node

This condition allows to branch the paths in a workflow and define the allocation of customer groups to every path. It's a good way to test the effectiveness of communication through a given channel and to verify content.   

The **Group stickiness** option in this node lets you keep a profile assigned to the same group in situations when the profile re-enters the node. By default, the profile may be assigned to a different group than before. With **Group stickiness** enabled, the profile is always assigned to the same group as the first time. 

The following list outlines the differences in a flow between group stickiness enabled and disabled:

1. A profile enters a workflow.
2. A profile arrives at the ABx Test node.
3. A profile is assigned to the group `A`. 
4. A profile finishes the workflow.
5. A profile re-enters the workflow.
6. A profile arrives at the ABx Test node. 
7. The profile is assigned to a group:
    - **Stickiness enabled**: Always to group `A`, same as the first time.
    - **Stickiness disabled**: Any group, possibly `A` again.


   <div class="admonition admonition-important"><div class="admonition-icon"><svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2.5"><path stroke-linecap="round" stroke-linejoin="round" d="M12 8v4m0 4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" /></svg></div><div class="admonition-body"><div class="admonition-content">

   Enabling the **Group stickiness** option may result in an uneven distribution of the test group percentages, especially noticeable with a workflow audience of fewer than 1,000 profiles. This behavior is common and expected.

   </div></div></div>


## Node configuration
---
1. Click the pencil icon on the node.
2. Click the **Add group** button. You can add up to 10 groups.
3. Optionally, you can select the **Equal allocation** option to evenly distribute customers between the paths.
4. If you want to always assign the customer to the same test group, enable the **Group stickiness** option.
5.  Optionally, you can enable **Generate a variant assignment event** option. Enabling this will generate group assignment events ([`automation.abTestVariantAssigned`](/docs/assets/events/event-reference/automation#automationabtestvariantassigned)) at each profile transition, which may increase costs due to the additional events generated.
6. Confirm by clicking **Apply**.

## Example of use
---

<figure>
 <img src="/api/docs/image/54176ad07f146575310749eba44b7c2f42c1b327/docs/automation/_gfx/abx-node-workflow.png" alt="Example of ABx Test condition" class="full">
<figcaption>Use of the ABx Test node</figcaption>
</figure>


<div class="admonition admonition-note"><div class="admonition-icon"><svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2.5"><path stroke-linecap="round" stroke-linejoin="round" d="M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" /></svg></div><div class="admonition-body"><div class="admonition-content">

You can have a look at the [use case](/use-cases/ab-test-mailing) that involves a workflow that includes ABx Test node.

</div></div></div>


The aim of this workflow is to compare two email templates. Group A receives a standard version of the newsletter, whereas Group B receives an experimental version. 

1. Start the workflow with the **Audience** trigger node. In the settings of the trigger, define the recipients and select a start date for the workflow.
2. Add the **ABx Test** condition. In the settings of the condition, divide the groups. Group A consists of 80% of the whole audience, whereas Group B consists of the remaining 20%.
3. Add the **Send Email** action nodes to every path. In the settings of the actions, select the appropriate templates.
3. When an email is sent, the workflow is completed. 
