Tracking Your Shopify Products With Voluum
Shopify is a leading commerce platform that allows anyone to set up their online store presence and sell their products. Thanks to integration with Voluum, you can track various events from your Shopify store in Voluum with ease.
Using Voluum with Shopify enables marketers or ecommerce store owners to connect all their advertising efforts in one place. With it, they can see how their ads are doing and how it translates to selling numbers.
The following article covers the setup for tracking visits and tracking conversions.
Before you start
You require several things to be able to track your Shopify-powered store products with Voluum:
-
An active Shopify account with:
- A valid payment provider added,
- A store created and products added,
- Optionally, a custom domain set up.
- Optionally, Shopify Plus subscription
-
An active Voluum account, with a tracking domain that has an SSL certificate enabled.
Voluum Note: Using an encrypted connection is a requirement in Shopify. If you do not have an SSL certificate enabled on your either dedicated or custom domain, conversion tracking will not work.
Once you have everything ready, proceed to the next step.
Visit tracking
Shopify allows you to use many sales channels, which include:
- Online Store
- Google Shopping
- Other
In order for the tracking to work, you need to direct your visitors to your store through a Voluum campaign URL. If you fail to do so, no click ID value will be assigned, and no conversion tracking will be possible. You can submit this campaign URL manually to any source of traffic, such as various ad networks. Activation of this campaign URL will be counted as a visit in Voluum.
There are two methods you can use to track your Shopify store:
- A direct one, where you put Voluum tracking script directly on your store's page (main or product). This requires having Shopify Plus, as it allows adding codes to store pages. Create a campaign with just a Shopify offer and direct link to it. Put the offer tracking script on your store's page.
- An indirect one, where you direct your visitors from your sales channel to an external landing page with Voluum script in it and then from this landing page to your Shopify store's page. This does not require having Shopify Plus. Add a lander to Voluum and create a campaign with a lander. Put a lander tracking script on your landing page and then redirect visitors to your store's page.
Add Shopify products as offers in Voluum
To be able to create a complete campaign funnel in Voluum, you need to have offer elements added to Voluum, with links to product pages submitted as offer URLs.
Voluum Note: If you run the following campaign funnels:
* Offers Only + Redirect
* Landers & Offers + Organic
* Landers & Offers + Direct
* Landers & Offers + Redirect
you should also add the following parameters to the offer URL after the ? character: cpid={campaign.id}&cid={clickid}. This will allow Voluum app in Shopify to recognize, which campaign is responsible for a conversion and will avoid generating a new click id (duplicating a visit).
If you run a campaign funnel with an offer only and a direct method, you don't need to add anything to an offer URL.
- In Voluum, go to Offers.
-
Click the Create button and select the Offer option from the drop-down menu.

- In the New offer form, provide a name for the offer in the Offer name text field.
- Paste a link to the product page in the Offer URL text field.
-
Click the Save button.

Repeat the steps above until you add all products as offer elements to Voluum.
Track conversions with integration
Voluum Note: Due to open nature of Shopify infrastructure, we're unable to ensure that our app works in all configurations. Certain themes, apps or modifications might disrupt our integration.
Thanks to Voluum and Shopify integration, user can now:
- Map their Voluum offers with the specific Shopify products (with a use of Offer IDs)
- See 'add to cart' results for specific products in Voluum
- Track the purchases and the revenue.
In order to set up integration, follow the steps below:
- Go to Shopify App Store and install Voluum app.
- Go to Themes.
- Click Customize.

- Go to App embeds.

- Enable Voluum app extension.

- Go to Products tab and add offer IDs to your products. You can grab them from Voluum after enabling the 'Offer ID' column.

- Now you have to create custom conversions for ‘Purchase’ and ‘AddToCart’ events in Voluum.The parameters for custom conversions are
purchase
add_to_cart

- Please also consider:
- It is recommended for ‘AddToCart’ custom event to leave “Include in conversions” column option disabled - the column for ‘AddToCart’ will be added anyway in reports, but these won’t be included in overall conversions column (and overall conversions column will contain only actual purchases).
- Note that each ‘AddToCart’ action will be firing a separate ‘add to cart’ conversion to Voluum.
Track Conversions without integration
Recently, Shopify has enabled its users to track custom events such as checkout_started, checkout_completed, and payment_info_submitted. The full list of events can be found here.
These events can be tracked in Voluum as Custom Conversions by adding our Conversion Tracking Script to the predefined code provided by Shopify. You can follow the steps below or watch a video.
- Add Custom Conversion in Voluum for each event you wish to track.

- Prepare Voluum Conversion Tracking Script
- add et parameter and match it with the corresponding et parameter value taken from the Custom Conversion
- for checkout_completed, you can also use a predefined checkoutTotalPrice variable to pass the order total value
- exemplary Conversion Tracking Script with et and payout parameters:
(function(a,b,c){a= https://voluum_domain/conversion.js? cid=OPTIONAL& payout=${checkoutTotalPrice} &txid=OPTIONAL &et=checkout_com pleted;var d=b.createElement("script"),e=b.scripts[0];c=(b=b.cookie.match(/(^| )vl
cid=([^;]+)/))?b.pop():c.getItem("vl-cid-expires")&&+c.getItem("vl-cid-expires")>(new
Date).getTime()?c.getItem("vl-cid"):null;c&&(-1<a.indexOf("cid=")?a=a.replace(/cid=.*?
(&|$)/,"cid="+c+"&"):
(b=-1<a.indexOf("?")?"&":"?",a+=b+"cid="+c));d.src=a;e.parentNode.insertBefore(d,e)})
(window,document,localStorage);
Voluum note: In order to use additional dynamic tokens, like checkoutTotalPrice, the URL in the
script must be changed to a template literal (` character at the beginning and at the
end of the URL), and the token must be added in the following format:
${checkoutTotalPrice}
3. Embed the edited Voluum Conversion Tracking Script into the predefined Shopify code taken from this site → selected event → Custom Pixel
The code extended with the Voluum Conversion Tracking Script should look like below. You can also find the complete script available here.
analytics.subscribe('checkout_completed', (event) => {
// Example for accessing event data
const checkout = event.data.checkout;
const checkoutTotalPrice = checkout.totalPrice?.amount;
const allDiscountCodes = checkout.discountApplications.map((discount) => {
if (discount.type === 'DISCOUNT_CODE') {
return discount.title;
}
});
const firstItem = checkout.lineItems[0];
const firstItemDiscountedValue = firstItem.discountAllocations[0]?.amount;
const customItemPayload = {
quantity: firstItem.quantity,
title: firstItem.title,
discount: firstItemDiscountedValue,
};
const paymentTransactions = event.data.checkout.transactions.map((transaction) => {
return {
paymentGateway: transaction.gateway,
amount: transaction.amount,
};
});
const payload = {
event_name: event.name,
event_data: {
totalPrice: checkoutTotalPrice,
discountCodesUsed: allDiscountCodes,
firstItem: customItemPayload,
paymentTransactions: paymentTransactions,
},
};
// Example of Voluum Tracking Script
(function(a,b,c){a=`https://voluum_domain.com/conversion.js?cid=OPTIONAL&payout=${checkoutTotalPrice}&txid=${order_id}¤cy=${currency}¶m1=${timestamp}¶m2=${client_id}&et=purchase`;var d=b.createElement("script"),e=b.scripts[0];c=(b=b.cookie.match(RegExp("(^| )vl-cid=([^;]+)")))?b.pop():c.getItem("vl-cid-expires")&&+c.getItem("vl-cid-expires")>(new Date).getTime()?c.getItem("vl-cid"):null;c&&(-1<a.indexOf("cid=")?a=a.replace(/cid=.*?(&|$)/,"cid="+c+"&"):(b=-1<a.indexOf("?")?"&":"?",a+=b+"cid="+c));d.src=a;e.parentNode.insertBefore(d,e)})(window,document,localStorage);
});
});
4. Add the edited code in Shopify → Settings → Customer events Pixels → Add custom pixel.
Paste the code and save changes.


