How can we help?

Install Tracking Code On a Shopify Website

Updated Date:

How to Install ClickSambo on a Shopify Website

To protect your Shopify store, add both ClickSambo tracking codes to your theme.

You need two codes: the HEAD code (the main tracking script) and the BODY code (a NoScript fallback). In Shopify, you add both to your theme's theme.liquid file, which covers your home, product, collection and other storefront pages.

Step 1: Get Your Tracking Codes

  1. Log in to your ClickSambo dashboard.

  2. Go to Account Settings > Domain Tracking Setup.

  3. Select your domain and keep this tab open; you will copy the HEAD and BODY codes from here.

Step 2: Add the Codes to theme.liquid

  1. In your Shopify admin, go to Online Store > Themes.

  2. Back up first (recommended): click the … menu on your live theme and select Duplicate.

  3. Click the … menu on your live theme again and select Edit code.

  4. Under the Layout folder, open theme.liquid.

  5. Find the closing </head> tag and paste the HEAD code on a new line just before it.

  6. Find the opening <body> tag and paste the BODY code on a new line right after it.

  7. Click Save.

What About Checkout Pages?

Shopify's checkout, Thank you and Order status pages do not use theme.liquid, and Shopify has retired the Additional scripts field that was used to add custom code there. You do not need to add the ClickSambo codes to these pages: visitors from your ads land on your storefront pages, which the theme installation already covers.

Step 3: Verify the Installation

  1. Open your website in an incognito/private window.

  2. Right-click the page and select View Page Source.

  3. Press Ctrl+F (Cmd+F on Mac) and search for cdn.clicksambo.com (HEAD code) and ping.clicksambo.com (BODY code).

Both codes found? The tracking codes are installed correctly. Make sure your Google Ads account is connected as well, so ClickSambo can protect your campaigns.

Did this answer your question?
  • clicksambo-sad
  • clicksambo-neutral
  • clicksambo-happy
Partner Program

Ready to grow with ClickSambo?

Join our partner program and turn ad-fraud protection into a scalable, recurring revenue stream.

Apply to the program
close

ClickSambo support is available!

Whatsapp Sohbet
Customise Consent Preferences
Cookies
Cookies Other
Always Active

Other uncategorised cookies are those that are being analysed and have not been classified into a category as yet.

Cookies Advertisement

Advertisement cookies are used to provide visitors with customised advertisements based on the pages you visited previously and to analyse the effectiveness of the ad campaigns.

Cookies Analytics

Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics such as the number of visitors, bounce rate, traffic source, etc.

Cookies Performance

Performance cookies are used to understand and analyse the key performance indexes of the website which helps in delivering a better user experience for the visitors.