Documentation Index
Fetch the complete documentation index at: https://auth0-feat-testing-docs.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Experiment Center is currently in Beta. This feature is available to select design partners only and is not supported for production use. To learn more about Auth0’s product release cycle, read Product Release Stages.
Prerequisites
- A Management API token with the following scopes:
create:experimentation,read:experimentation,update:experimentation,delete:experimentation - Your tenant must be enabled for the Experiment Center Beta (contact your Auth0 account team)
Base URL
All Experiment Center endpoints are under:Step 1: Create a feature flag
A feature flag defines the feature you are testing. It contains typed configuration parameters with default values (the baseline state).feature_flag_id (prefixed identifier, e.g., flg_...). Save this value for the following steps.
Step 2: Create variations
Variations represent the different treatments within a feature flag. The control variation uses empty overrides (inherits the baseline). The treatment variation specifies which parameters differ.Create the control variation
Create the treatment variation
variation_id values from the responses.
Step 3: Activate the feature flag
A feature flag must be inactive status before any experiment referencing it can be activated. Activation requires at least 2 variations.
Step 4: Create the experiment
An experiment references a feature flag and defines how traffic is allocated across variations.experiment_id from the response.
Allocation weights must sum to 100. Exactly one allocation must have
is_control: true.Step 5: Validate the experiment
Before activating, you can check whether the experiment passes all validation rules:is_valid (boolean) and an errors array. If is_valid is true, you are ready to activate.
Common validation errors:
| Error code | Cause |
|---|---|
experiment_invalid_allocation_weights | Weights do not sum to 100 |
experiment_missing_control | No allocation has is_control: true |
variation_not_from_flag | A variation ID does not belong to the referenced feature flag |
feature_flag_not_active | The referenced feature flag is not in active status |
experiment_active_limit_exceeded | Another experiment is already active (Beta: one per tenant) |
Step 6: Activate the experiment
started_at timestamp is set automatically.
Test with query parameters
You can force a specific variation during testing by passing query parameters on the/authorize URL:
| Parameter | Description |
|---|---|
experiment_id | Force enrollment in a specific experiment |
variation_id | Force a specific variation (requires experiment_id) |
segment_id | Force a specific segment match (requires experiment_id) |
draft. This enables a testing workflow where you create an experiment, verify both variants render correctly using query params, and then activate.
Query parameters influence variant assignment only. They do not grant access to experiment data or bypass tenant security policies.
Verify enriched tenant logs
Once the experiment is active and auth transactions are flowing, verify that tenant log events contain experiment metadata:- Navigate to Auth0 Dashboard > Monitoring > Logs or use the Management API logs endpoint.
- Look for recent authentication events (successful login, signup).
- Confirm the event details include:
experiment_id,variant_id, andsegment_id.
Use experiment context in your code
Once the experiment is active, experiment context is injected into runtime surfaces automatically.ACUL components
Enable experiment context on a screen by addingexperiment_center to the screen’s context_configuration:
Actions
Read experiment context from the event object in post_login, pre_user_registration, or post_user_registration triggers:Forms
Pass experiment context to Forms via thevars property in an Action:
{{vars.variation_id}} or {{vars.show_passkey_prompt}}.
Complete the experiment
When you are ready to conclude the experiment:ended_at timestamp is set automatically. The experiment configuration (including the winning variation’s overrides) is retained so you can reference it while applying the configuration change to your tenant.
Promotion is manual at Beta. After completing the experiment, update your tenant configuration to match the winning variation’s behavior. Automated promotion is a future capability.
Experiment lifecycle reference
| Status | Description |
|---|---|
draft | Created but not running. Can be tested via query parameter overrides. |
active | Running. Variant assignment and context injection active for all auth transactions. |
paused | Temporarily suspended. No new assignments; in-flight sessions continue. |
completed | Concluded. Configuration retained for reference during manual promotion. |
archived | Soft-deleted via DELETE. Hidden from default list views. |
draft → active, active → paused, paused → active, active/paused → completed, draft/paused/completed → archived.
A completed experiment cannot be reactivated. Create a new experiment to run again.