BigCommerce
There are two ways to connect BigCommerce. The server connector (recommended) syncs your catalog and receives orders over BigCommerce's REST API. The snippet is the fallback when you'd rather not create an API account.
Connect the server connector (recommended)
The connector reads your v3 catalog and subscribes to order and product events. It also reads cost_price for each variant (one specific size or color of a product), so your profit metrics work.
Create a store API account
In your BigCommerce control panel, go to Settings → API → Store-level API accounts and click Create API account. Give it these read scopes: Products, Orders, Information & Settings, and Webhooks (Modify). Copy the Access token, Client ID, and your store hash (the value in the API path stores/{hash}/v3).
Connect in A vs B
In A vs B, open Commerce → Sources and choose BigCommerce. Paste your Store hash and API token. Client ID is optional. We verify the token, register webhooks, and start a full catalog import.
- Paste your Store hash and API token. Client ID is optional.
- Click Connect BigCommerce to verify the token, register webhooks, and start the catalog import.
What syncs automatically once connected:
- Catalog: titles, prices, availability, variants, and cost price (so profit and margin metrics work for BigCommerce).
- Orders: new orders and updates arrive and appear in your orders summary.
BigCommerce webhooks are notification-only. A delivery just tells us something changed. We then fetch the full record from the API ourselves. These deliveries carry no body signature, so we secure them with a per-connection secret header set when the webhook is registered.
Attribution still comes from the snippet: install it (below) so orders can be linked to the A vs B visitor who placed them. Orders received without a visitor link are counted as unattributed: they show in your orders totals but not in experiment results.
Snippet fallback
If you'd rather not create an API account, install the snippet with Script Manager and record purchases on the confirmation page.
Your snippet comes from Project Settings → Snippet in the A vs B dashboard:
<script>window.avsb=window.avsb||{};window.avsb.q=window.avsb.q||[];window.avsb.ready=window.avsb.ready||function(f){window.avsb.q.push(f)};window.avsb.on=window.avsb.on||function(n,f){var t=['on',n,f];window.avsb.q.push(t);return function(){t[0]=null}};window.avsb.consent=window.avsb.consent||{set:function(s){window.avsb.q.push(['consent.set',s])},get:function(){return{}}};window.avsb.track=window.avsb.track||{};['event','segment','purchase','cart'].forEach(function(m){window.avsb.track[m]=window.avsb.track[m]||function(a,b){window.avsb.q.push(['track.'+m,a,b])}});(function(){window.avsb._t0=Date.now();window.avsb._df=fetch('https://cdn.avsb.cloud/YOUR_SNIPPET_KEY/datafile.json').catch(function(){});var d=document,e=d.documentElement,s=d.currentScript,a=s&&s.getAttribute('data-avsb-timeout'),t=a==null?3000:+a;if(!(t>0)||window.avsb.version)return;e.style.opacity='0';e.style.pointerEvents='none';window.avsb._t=setTimeout(function(){e.style.removeProperty('opacity');e.style.removeProperty('pointer-events')},t)})();</script><script src="https://cdn.avsb.cloud/snippet.js?id=YOUR_SNIPPET_KEY" data-avsb="YOUR_SNIPPET_KEY" async></script>Open Script Manager
Go to Storefront → Script Manager and click Create a Script.
Configure the script
Name it A vs B Snippet. Set Placement to Head, Location to All pages, Script category to Essential, and Script type to Script.
Paste the snippet
Paste both tags (with your real key) into the Script contents box and click Save.
Then record purchases on the order confirmation page. BigCommerce's conversion tracking box substitutes order tokens for you:
<script> window.addEventListener('load', function () { if (window.avsb && window.avsb.track) { window.avsb.track.purchase({ orderId: '%%ORDER_ID%%', total: parseFloat('%%ORDER_AMOUNT%%'), currency: 'USD' // your store currency: ISO 4217 }); } });</script>Orders are deduplicated by orderId (last write wins), so running the snippet alongside the server connector is safe. If your store already pushes a GA4 purchase event to window.dataLayer, you have another option. Turn on Google Analytics 4 / dataLayer on your project's Product catalog page instead, once your product catalog is connected.
Verify
Place a test order, then open Commerce → Orders in the A vs B dashboard. It shows recent orders, totals by currency, and any orders that couldn't be attributed to an experiment exposure. An exposure is the moment a visitor is counted in a test. See the orders & attribution guide for the full picture.
- Unattributed orders are ones we could not link to an A vs B visitor.
- Order totals, grouped by currency.