Flag Configuration

How to create and configure flags in Versia

Creating a Flag

  1. Open the Versia dashboard
  2. Click “Create Flag”
  3. Enter a flag key (e.g., banner-cta)
  4. Add your variants
  5. Choose a mode
  6. Save

Flag Modes

Static

Returns the same variant for everyone. Great for feature toggles and kill switches.

Percentage Rollout

Splits traffic by fixed percentages (e.g., 80% control, 20% new design). Great for gradual rollouts.

Exclusion Rules

Returns specific variants based on evaluation context attributes:

  • plan eq "enterprise" → show enterprise experience
  • country eq "de" → show German version
  • device eq "mobile" → show mobile layout

Rules are checked in order. First match wins. The attribute names must match the keys you pass in your evaluation context.

Reward-Driven

Versia picks the best variant automatically based on reward data. Just enable it and start sending rewards.

Variants

You can use:

  • Strings: "sign-up-free", "start-trial", "learn-more"
  • Booleans: true, false
  • Numbers: for configuration values

Combining Modes

You can mix exclusion rules with reward-driven optimization. For example:

  • Enterprise users always see the enterprise variant (exclusion rule with plan eq "enterprise")
  • Everyone else gets reward-driven optimization (default rule)

Both exclusion rules and reward-driven mode use the same evaluation context. Pass it once and both features benefit from it.

Tips

  • Start simple. One flag, 2-3 variants, reward-driven mode. Get comfortable before adding complexity.
  • Use clear names. homepage-cta over flag-7.
  • Clean up old flags. Archive flags you’re no longer using.