Skip to main content
Create rules to assign variants to users in a segment.
See Rules and Variant Assignment in the reference for details on how rules work, assignment types, and best practices.

Before You Begin

Before creating a rule, you need:
  1. A flag with a defined schema and variants
  2. An allocated segment that defines your target audience

Create a Basic Rule

Assign all users in a segment to a single variant:

Create an A/B Test Rule

Randomly assign users to control or treatment (50/50 split):

Create a Multi-Variant Rule

Assign users across three variants (40/30/30 split):

Create a Fall-Through Rule

Create a rule that matches but passes to the next rule:

Create a Client Default Rule

Assign users to their client-specified default values:

Enable a Rule

Newly created rules start disabled. Enable a rule to activate it:

Update a Rule

Change variant assignments or the segment:

Reorder Rules

Change rule evaluation order by updating priority (lower numbers evaluate first):

Delete a Rule

Remove a rule from a flag:

Use a Custom Targeting Key

Specify a different field for randomization (for example, device instead of user):

Next Steps

After creating rules:
  1. Resolve flags to test your rules with different evaluation contexts
  2. Apply flags to track which users see which variants
  3. Monitor your experiments and adjust rules as needed