Skip to main content
November 9, 2026
Tapfiliate’s recently released Shopify integration is a huge step up from our previous integration option. However (and due to Shopify’s current limitations), Tapfiliate’s plug-and-play integration option means you connect one Shopify store per one Tapfiliate account.
This is why we’re keeping our old integration option available to you.
It’s an easy-to-install, code-based integration that you can install in each Shopify store you’d like to track in.

Code-based integration for Shopify

Rather follow a step-by-step guide? Here are the steps towards installing Tapfiliate code into your Shopify store

1. In your shop’s admin environment, please go to: Log in to your shop > Open Setting > Click on Customer events > Add custom pixel > Name the pixel and press Add pixel.
  1. Permissions: Choose Required > Check the boxes next to Marketing and Analytics.
  2. Data sale: Please, choose Data collected does not qualify as data sale.
  3. Next, in the Code section, paste the following code:
Make sure to replace YOUR ACCOUNT ID with your actual account id.
4. Hit save > Press Connect, and you are all done!
5. Test your integration. Follow a test affiliate’s referral link to your store and complete a test purchase, as described in How to Validate Your Tracking. Then check that the click and the conversion appear in your Tapfiliate account. The integration tester (tap_test=true in your store’s address) isn’t available with this integration: the code runs in a Shopify custom pixel, which has no access to your store’s pages. Test without tap_test=true in the address, and accept your store’s cookie banner if it shows one.

FAQ

Does this code track refunds and order cancelations?

These scripts will only track clicks and conversions. Anything that happens after checkout (refunds, order cancelations, etc.) will not be picked up by this code-based integration.
However, you or a developer could definitely set up the logic to support this on your end. Our “Create deeper integrations” article lists which endpoints to use for each process.

Is cross-domain tracking supported?

Not by this integration: it can’t carry the click from one domain to another. Its script remembers the affiliate’s click with a first-party cookie on the domain where the visitor lands, and a store on another domain can’t read that cookie. If your affiliate links land on a site on another domain, contact us via live chat or at support@tapfiliate.com to work out a setup.
How do I track multiple commission types/SKUs within this integration?
It is now possible to distinguish different commission types in your store when sending the conversion data. To proceed, you have to adjust your code in the Code section as follows:
  1. Create the identifiers for extra commission types in your Tapfiliate account by following our guide.
  2. In your Shopify tracking code you’ve added to the Code section, pass the identifier as the fifth argument of the conversion call, after the options object, as in the example below:
Replace COMMISSION_TYPE_IDENTIFIER with the identifier of your commission type.

What happens if I install both the code-based integration and the plug-in at the same time in the same store?

If you have both the code-based integration and the plug-in installed, this is what will happen:
  • Clicks will track twice. This is because you will have two click-tracking scripts installed in your store.
  • Conversions will track only once. We perform de-duplication based on the external_id value (in Shopify’s case, the order number). This means we’d only track once per transaction, and you do not have to worry about duplicates.

I would like to use the new Shopify integration. How do I remove the tracking scripts?

We recommend tracing back your steps and deleting the custom pixel previously created.
Here’s where you can locate your old integration:
Open Setting > Click on Customer events > Choose the Custom Pixel > Press Delete pixel.
If you installed Tapfiliate before custom pixels existed, also remove the old Tapfiliate script from your theme: Online Store > Themes > Edit code > theme.liquid.