Spec: A/B Testing Events

This guide explains what data should be sent to Segment from A/B Testing tools and hence is targeted to partners who send A/B testing data back into Segment rather than targeted to customers themselves. The semantic events detailed below represent the ideal for A/B Testing events.


Every A/B Testing tool is built around the concept of showing visitors an experiment with changes to the page. Each experiment can have multiple variations shown to different random samples of visitors.


The one semantic event for recording A/B Test experiments is:

Experiment Viewed

This event will be sent automatically every time a customer sees a variation of an active A/B Test when using some A/B testing tools via Segment. You don’t actually have to make these track calls! Note that the A/B testing tools will need to be loaded synchronously in order for these events to fire properly.


This event supports the following semantic properties:

experiment_idStringThe experiment’s ID.
experiment_nameStringThe experiment’s human-readable name.
variation_idStringThe variations’s ID.
variation_nameStringThe variation’s human-readable name.

Questions? Need help? Contact us!
Can we improve this doc?
Email us: docs-feedback@segment.com!