Skip to main content
Kameleoon randomly allocates a variation to a visitor by default. The statistical paper explains the assignment algorithm logic in the “Kameleoon’s assignation algorithm” section. The default function follows:
Overload this function to change how Kameleoon selects and displays variations. For example, selecting a variation based on a JavaScript variable is often beneficial:
Add the custom code to the account:
  1. Use the left menu to go to Admin > Projects.
  2. Click Edit on your project’s row.
  3. Click the Scripts tab.
The Scripts tab with the Global custom script and Variation selection script editors
  1. Next to Variation selection script, click Edit, then add the script.