Custom tracking codes are available on Shopgate.
In this article, you will find out how to embed a custom tracking code for your Shopgate apps and mobile website.
With the Shopgate custom tracking code feature, you are able to track a wide variety of customer behaviors across selected mobile platforms & pages.
What is a custom tracking code?
Generally speaking, a custom tracking code is a piece of tracking code that someone wrote or customized specifically for your shop.
To be more specific, you are using a custom tracking code if...
- your shop uses a tracking service other than the ones mentioned below, or
- you have modified the code provided to you from a tracking service mentioned below
Integrated Tracking Services at Shopgate
If you use an original tracking code from these services, please refer to the documentations here.
|Google Analytics||Google Analytics Universal||Google Adwords||Adobe Dynamic Tag Management|
|econda||AppsFlyer||Facebook Pixel||Facebook Analytics for Apps|
Entering your tracking code
- Click on Settings from the menu bar, then select Tracking Tools.
- Locate the Tracking codes section, select a platform and a page to display the code, and click +Add. Click here to see the available platforms and pages
- Enter a title and your tracking code in the script editor. Turn Autovalidation to ON - your code will be validated before it can be saved. Click Save.
☞ The validation function looks for coding mistakes and provides extra security to your shop. If you run into any validation errors, look here for a few tips.
That's it! You have successfully set up a custom tracking code. Repeat the steps here to enter another code if needed.
To convert this code, follow the simple steps and rules below:
Rule 1: The <script ...> and </script> tags should NOT be included
Rule 2: External files (src) need to be converted
An external file inside the <script> tag can be converted by using the following formular:
Rule 3: Do NOT include the <noscript>...</noscript> tags or anything in between
Code within the <script>...</script> tags can be converted by simply removing everything between the <noscript> </noscript> tags.
Frequently Asked Questions
Which platforms & pages can I track using the custom code?
In the table below are the available platforms and pages you can choose from. You can use a tracking code on any combination of a platform and a page*.
|Available Platform||Available Page|
|✓ All platforms
✓ Mobile Website Smartphone
✓ Mobile Website Tablets
✓ Mobile Website Smartphone + Tablets
✓ Native Apps Smartphone
✓ Native Apps Tablets
✓ Native Apps Smartphone + Tablets
|✓ All pages
✓ Start Page / Homepage
✓ Product List
✓ Product Detail Page
✓ Shopping Cart
✓ Login / Registration
✓ Checkout Summary
✓ Checkout Success
What are the rules and tips on formatting the custom tracking code?
There are a few things you need to know when you write or modify a tracking code in the Shopgate script editor:
- If your code contains <script> </script> tags, refer to Rule 1 and Rule 2.
- If your code contains <noscript> </noscript> tags, refer to Rule 3.
- Comment a single line with "//", and a paragraph with "/* */".
- Press CTRL+Space to show a list of Shopgate variables available on the page selected for this tracking code.
You are using a tracking pixel if you see an HTML snippet similar to this in your tracking code:
☞ To learn more about the tracking code functions and options, please read Shopgate Tracking Variables and Events.