The purpose of Tag Integration is to integrate Webtrekk and other plugins easily into your website using a graphical user interface. In this Best Practice we will show you how to setup basic tracking for your website with Tag Integration.
In general, in Tag Integration you have to set up a container for each domain (i.e., usually for each account). To each container, several plugins (e.g., Webtrekk Plugin, Teaser Tracking Plugin) can be assigned. Further, you can define rules (e.g., certain URLs, certain parameter values or combinations of both). To each plugin rules are assigned that determine under which conditions a plugin is executed.
In the following example we will set up the tracking for the domain demoshop.webtrekk.com with the help of Tag Integration. To keep the example simple, we will not measure things that have to be configured outside of the "Basic" and "Event" tabs. These configurations suffice to get data for many important analyses, e.g., Traffic analysis, all Geography, Pages and Technology analyses, as well as Entry Sources and Referrer analyses.
Step 1: Downloading the Tracking script and inserting it in the pages that are to be tracked
For the current Pixel version, you find this file here as a ZIP file together with the documentation.
In the tiLoader.min.js file, you now have to change the tiDomain to your track domain and the tiId to your track ID. You can look up your track ID in Q3 at Configuration > System Configuration > Account. If you want to host the file generated by Tag Integration on your own server, you also have to adapt the customDomain.
When you put the file on your server, you can integrate it in the page to be tracked by inserting the bold line:
Titel der Seite
Inhalt der Seite
Step 2: Creating a Container
After logging in, choose the "Tag Integration" module.
To create a container, click on New Container.
With the help of container you define which domain or subdomain you want to track.
To track a website, choose the type Web.
At Domain Inclusion, type in the domain that you want to track; at Domain Exclusion, type in all subdomains of this domain that you want to exclude from tracking.
Step 3: Add Plugins
Now you can choose the plugins that you want to use for the domain or subdomain tracked by the container. Click on Add Plugin.
Step 4: Basic Configuration of the Webtrekk Plugin
To activate tracking, some settings have to be adjusted in the Webtrekk Plugin.
Click on Webtrekk Plugin to configure the plugin:
Enter the following information:
Webtrekk track ID: The track ID for your account. You find your track ID in Webtrekk Q3 at Configuration > System configuration > Data Collection.
Webtrekk track domain: The domain of your tracking server. If you use a custom track domain, it's a subdomain of the tracked domain. If not, it's a subdomain of a webtrekk domain. If necessary, you can read up the track domain in a confirmation mail sent by Webtrekk.
Domain: The domain to be tracked. Multiple domain or subdomains can be entered by using regular expressions. Alternatively, different domains can be separated by semicolon. In our case we only track the domain "demoshop.webtrekk.com". Usually, the domain entered here should be the same as the one entered at "Domain inclusion".
Cookie settings: Choose between "First-party" and "Third-party" cookies.
To assure exact data collection, we recommend to use First Party cookies.
Position of "sendinfo"-call: You can pass tracking information to Webtrekk by using the function wt.sendinfo(). Here you define when the function is executed. As a standard, the option "Execute in <head>" is chosen.
In the tab "event" your can activate the automatic tracking of HTML links. To this end, at "event tracking" and "event tracking type", choose the option "link".
Step 5: Creating rules for the plugins
Now you have to define the rules according to which the plugins are executed.
In our example the tracking should be executed for the whole domain or subdomain that was specified in the container. You can create the rule "All Pages" as follows:
Step 6: Assign rules to the plugins
Click on Containers and choose the container created by you. Click on Webtrekk Plugin. Now you can choose the rule "All Pages".
Step 7: Publish container
When all settings are done, the container can be published to finally integrate Webtrekk into the website.
Please note that data in Webtrekk generally is updated once per hour (i.e., after accessing the website it will take some time until you will see the access in Webtrekk).
If you want to view analysis data close to realtime, you can book the Live Analytics module. With this module, you can see the access within a few seconds.
Further information on the Review of Data Collection can be found in the corresponding training chapter.