Why layers exist
The day you run more than one experiment at a time, you create a risk: if a user is simultaneously in two experiments that affect related parameters, you can’t cleanly attribute the observed behaviour to either one. Layers solve this by partitioning the parameter space:- Within a layer — only one policy applies to a given user. Mutual exclusivity is guaranteed.
- Across layers — policies can overlap freely because they control different parameters. Independence is guaranteed by orthogonal bucketing.
Every project has a base layer that’s created automatically. New parameters land in the base layer by default. The base layer can’t be deleted.
Orthogonal bucketing
Each layer computes the user’s bucket independently:bucketCount is a project-level setting (default 10000). A higher count gives finer-grained allocation ranges and smoother rollouts.
Example
Two concurrent experiments in different layers:| Layer | Experiment | Parameters |
|---|---|---|
| Layer 1 | Checkout color test | checkout.button.color |
| Layer 2 | Pricing experiment | pricing.discount_pct |
user_789 gets:
- Layer 1:
hash("user_789" + "layer_1") % 10000 = 3420→ Control (range 0–4999) - Layer 2:
hash("user_789" + "layer_2") % 10000 = 8170→ Treatment (range 5000–9999)
Bucket ranges
Each layer hasbucketCount buckets (typically 10000). The policies within a layer divide that space into non-overlapping allocation ranges:
Organising parameters into layers
A few guidelines:- Group parameters tested together. If
checkout.button.colorandcheckout.button.textare always swept in the same experiment, put them in the same layer. - Separate independent concerns. Pricing experiments belong in a different layer from UI experiments.
- Use the base layer for stable configuration. Parameters that are essentially always on, or that you only flip occasionally for kill-switches, are fine in the base layer.
A parameter belongs to exactly one layer. You can move a parameter between layers in the dashboard, but every move resets the assignment — users will hash into different buckets in the new layer.
Eligible bucket ranges
A policy can optionally narrow itself to a sub-range of the layer (an eligible bucket range). This is how you fit several non-overlapping experiments inside a single layer:Next steps
Policies
How allocations and targeting work inside a layer.
A/B testing
Run your first experiment.