All Collections
Tracking scripts
Introduction to our tracking script
Introduction to our tracking script
Christiaan Proper avatar
Written by Christiaan Proper
Updated over a week ago

Our tracking scripts enable us to gather behavioral data from visitors. It also enables us to serve website touchpoints, such as notifications and embedded content. There is a basic tracking script, but it can also be extended with extra scripts to gather extra behavioral data.

Speed and loading

Our script is loaded asynchronously, which means it is loaded alongside other web elements in the webpage. This has the advantage that we cannot slow down other content on the website (like images not loading because our script is still loading). If there is a slowdown on our script, for whatever reason, the request to our API for loading/sending data is automatically timed out after five seconds. This is to make sure that visitors on our clients’ websites will never experience slowdowns because of us.

Data gathering, Cookies & Fingerprinting

The basic script gathers information about the page views of visitors. So the URLs they’re visiting with the associated page names.

If you connect a data source with content to Datatrics, we can also track content views. So if there’s an ecommerce tool connected (like Magento, Shopify, Lightspeed, PrestaShop), Datatrics will synchronize all products which you can find at https://app.datatrics.com/content. These products have URLs as an attribute. If a visitor views a URL and it matches a product URL, we will automatically register a content (in this case a product) view.

Besides the gathering of page/content views, we gather a lot of extra visitor data. This included the referer (like Google/Facebook/https://www.domain.com/extra/evenmore/), device data (like type, brand, model, software, browser, IP address, etc.).

We hash the IP address (which basically means we make it a bit less accurate) and use the hashed IP address to gather the location of the visitor. After hashing we can target on ZIP code accuracy level, not on street / street number. This is done for privacy reasons. We have multiple databases with IP addresses and location data, to still make this as accurate as possible.

If a visitor enters a website, we start gathering all mentioned data and also store a cookie on the visitor’s browser. This is to easily recognize the same visitor when he visits the website again.

Recently there has been a trend for browsers to automatically delete cookies after a certain amount of days. Some people also use browser extensions for this. To tackle this problem, we create a browser fingerprint to recognize the same visitor. This uses data like mentioned above, but also screen resolution, the useragent, browser version, etc. Because of this, we can also identify/track visitors while they’re using an incognito window.

Another trend is the usage of ad blockers. We’re currently not listed in databases of ad blockers, but when we’re implemented via a tag manager which is, our script will of course also not be executed.

Multiple projects

As mentioned above, we have a lot of tracking methods to gather data and recognize visitors when they re-enter the website. But every visitor has a unique visitor ID per project. So when you’re on the website of one client, you won’t be recognized as the same visitor when visiting a website of another client.

Non ecommerce conversions

Because we track all page views, you can also track a page view as a conversion. When creating a new conversion at https://app.datatrics.com/project/conversions, you can select URL as a Match Attribute. This makes it possible to register the page view of a page where the URL contains /checkout/thankyou as a conversion.

You can also register an outclick to an external website as a conversion. So if it’s not possible to implement our tracking script in a booking engine, you can register the outclick to the booking engine as a conversion. For this example the Match Attribute needs to be External Website and the pattern looks at the URL of the external website.

The registration of URL based conversions really come in handy when a client wants to start ASAP or when there isn’t the technical knowledge or possibility to implement our advanced conversion scripts.

Did this answer your question?