AB Testing

Learn how to tag A/B test page variants in AnyTrack so Landing Page Reports show which variant generates the most revenue, not just the most clicks. Includes the pageVariant JavaScript snippet and setup instructions.

AnyTrack's pageVariant command tags each test variation so Landing Page Reports show which variant generates real revenue — not just which one gets more traffic. Compare conversion rates, average order value, and total revenue by variant to pick winners based on business outcomes.

Important

This setup requires adding a JavaScript snippet to each page variant. If you're not comfortable with code, share this guide with your developer.

Setup

Add the following snippet in the <body> of each page variant. The AnyTrack Tracking Tag must already be installed in the <head> section.

Replace MY_AB_TEST_PAGE_NAME with a unique name or ID for the variant:

<script>
  AnyTrack("pageVariant", "MY_AB_TEST_PAGE_NAME");
</script>

AnyTrack collects the variant name and reports it in the Landing Page Reports alongside all other metrics.


FAQ & Troubleshooting

FAQ was last reviewed on 2026-03-07

In the Landing Page Report. Filter or group by page variant to compare conversion rates, revenue, and ROAS across variants.
Yes. Assign a different pageVariant name to each version. AnyTrack tracks all variants and reports them separately.
Yes. As long as each variant loads a page where the AnyTrack Tracking Tag and the pageVariant snippet are present, the data is captured regardless of how the split is managed.