How to do A/B testing in chrome extensions

Viewed 459

I would like to do A/B testing on my chrome extension UI. I started with google optimize, however, it's asking for a url. I am sure other providers would ask the same.

How am I supposed to do an A/B in a chrome extension given that there's no url for them.

Nor can I use google tag manager to check if a button gets clicked by the user.

P.S: my chrome extension isn't a popup but gets injected to user's DOM.

1 Answers

I think you're correct that the plug and play tools for A/B testing will not quite work for your Chrome extension. Frankly, you might be stuck with a "home brew" solution.

That may sound scary, but it doesn't necessarily have to be. It'll be less "point and click" than the tools you mentioned, but if you don't have crazy amounts of experiments to run it could be viable.

Here's what I would build to make it work:

  1. Some way to randomly choose "A or B" for the current user, and persist that choice so they continue to see the same thing, and render one or the other. (Hopefully a small amount of reusable code.)
  2. Integrate a tool for data / event collection. Segment is really simple and integrates with tons of services to process the data. Straight up Google Analytics could possibly work as well. Point being, you don't need to build the data collection part.
  3. Use something to analyze the data. This might not be as "brainless" as it would have been in Google Optimize, but I'm sure if you manage to collect "Button clicks with A" and "Button clicks with B" you'll be able to make some pretty graphs somewhere.

If you get one experiment under your belt, the next one should be a simple matter of coding the "A" / "B" version and using the same infrastructure.

Related