Shopify Lead Tracking

SegMetrics allows you to track the page visits and web information of leads acquired through Shopify, by simply adding the tracking snippet to the shop you want to track.

When a customer purchases from Shopify, their contact information will be sent to the CRM that you have configured in SegMetrics. But you'll also want to connect the web history of those leads into the full customer journey. In order to do that, we'll want to install the tracking snippet on your Shopify pages, as well as special code on your purchase thank you page.

Get the SegMetrics Tracking Code

  1. In SegMetrics, go to your Site Setup page from the gear in the top menu, and copy the snippet code.
  2. If you haven't configured your Tracking Code previously, check out the Installing the Tracking Snippet instructions to set up your site correctly.

Install the SegMetrics Tracking Code on Your Shop

We recommend using Google Tag Manager for installing your SegMetrics code on your Shopify Site. This will make sure that the code is available on your pages, without having to edit each theme template.

However, if you would like to install the Tracking Code manually, please do the following:

  1. In your Shopify admin, click Online store, and then click Themes.
  2. In the theme drop-down, click Edit Code.
  3. Copy the Tracking Code snippet (above) from SegMetrics
  4. In your Shopify admin, open your theme.liquid file.
  5. Paste the code snippet as low in the <head> of the theme.liquid code as possible.
  6. Open your checkout.liquid file.
  7. Paste the code snippet as low in the <head> of the checkout.liquid code as possible.
  8. In your Shopify admin, click Save.

Configure Your Thank You Page

If you are a Shopify Plus customer, you do not need to configure this part of connection. However, non-Shopify Plus customers may not customize the  checkout.liquid file to install the code.

In that case, please follow the steps below to connect identify the user after purchase:

  1. From your Shopify admin, go to Settings > Checkout.
  2. Under Order processing, go to the Additional scripts text box.
  3. Make sure that the SegMetrics tracking code (above) is also on the Thank You page.
  4. Copy / Paste the identify script:

    <script type="text/javascript"> 
    _segq.push(['identify', '{{ }}']);
  5. Click Save

Still need help? Contact Us Contact Us