The Full Stack Developer Guide Developer Hub

Welcome to the Full Stack Developer Guide developer hub. You'll find comprehensive guides and documentation to help you start working with the Full Stack Developer Guide as quickly as possible, as well as support if you get stuck. Let's jump right in!

Get Started    

Create feature variables

Create a feature variable

Feature variables (also called remote feature configuration or remote variables) let you avoid hard-coding values in your code, so that Optimizely can dynamically assign those variables to your feature based on your test or rollout. For more information about what feature variables are, see Feature variables.

You can create variables of type Boolean, String, Integer, Double, or JSON. There is no character limit for a JSON variable value.

To define a feature variable with a default value in the Optimizely app:

  1. Navigate to Features and select a feature.
  2. Click Variable Keys and Types.
  3. Edit the Key, Type, and Default Value.
  4. Create as many feature variables as you need for that feature.
  5. Now, in your feature rollout or experiment, you can configure your variables with new values.
navigate to feature variables

navigate to feature variables

You can create variables of type Boolean, String, Integer, or Double.

For feature rollouts, you can configure different values for feature variables for each audience and each environment.
For experiments, you configure a different value for each feature variable in each variation.

Next Steps

Use your feature variables in an experiment or rollout.
See:
Roll out and roll back
Run feature tests with variables

Updated 24 days ago


Create feature variables


Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.