Skip to content

A/B testing

You could use A/B testing to test different variations of the same tour. This can help you tweak your tours and achieve the optimal onboarding experience.

Add a script after your after your HelpHero installation scripts.

<script>
HelpHero.update(function(user) {
// user is already assigned variant do nothing
if (user.variant) return null
var variants = ['A','B']
// assign user to variant
return { variant: variants[Math.floor(Math.random() * variants.length)] }
})
</script>

Now that user is assigned to a variant, we can create two variants of a tour. The first tour will have a funnel step targeting variant A and the second tour targeting variant B.