Create events
How to create and add an event in Optimizely Feature Experimentation.
Events are used to track the relative success of your experiment. Events track direct user actions, such as clicks, pageviews, form submissions, purchases, and scroll depth. For information on integrating events into your application code with the SDK, see Track events.
Create an event in Optimizely Feature Experimentation using the UI
To create an event that tracks user actions in the Optimizely Feature Experimentation app:
-
Go to Events and click Create New Event.
-
Enter:
- An Event Name.
- An Event Key (a unique identifier you will reference in your code when you call
Track Event
) . Event keys are automatically populated based on the Event Name with the following updates:- Uppercase characters are converted to lowercase.
- Non-alphanumeric characters are replaced with underscores.
Note
You can edit the pre-filled Event Key field.
- (Optional) a Description.
-
(Optional) Configure event properties
Beta
Event properties are currently in beta.
You can select built-in properties or create custom event properties. Event properties let you track and view additional information on the Optimizely Experimentation Results page and use it to disassemble and analyze your events more in-depth. You can have 15 properties total, including built-in and custom properties.
Default properties
Select any of the built-in properties to add it to the event.Custom properties
To create a custom property to add to the event:- Click Add custom property.
- Enter a name.
- Select the type of custom property from the data type drop-down list.
- Click Create Event.
Add events to your experiments
To add an event to your experiment in the Optimizely Experimentation application:
-
Go to Flags and select a flag.
-
Select the environment and click the rule to which you want to add an event.
-
Select the event you created earlier in the Metrics field or click Create new event. Click All projects to see events from your Feature Experimentation and Web Experimentation projects.
See Run A/B tests for information on creating an A/B test rule.
Track events in your application code
See the Track Event
documentation in your preferred SDK to implement event tracking in your code:
Create metrics
Metrics measure the success of your experiment by telling you whether an experiment is winning, losing, or inconclusive. Metrics are derived from events, which directly track actions like clicks, pageviews, form submissions, purchases, and scroll depth.
Optimizely Feature Experimentation uses a natural-language metrics builder in the UI that lets you define and add metrics to your experiments and campaigns.
See Create a metric in Optimizely using the metric builder for instructions on creating metrics in Feature Experimentation.
Updated 21 days ago