Choosing your Tracking Method: FH Tag Manager or FH JS
You can configure tracking in FirstHive CDP using the FirstHive CDP Tag Manager (FTM) or the FirstHive CDP JavaScript (JS) tracker code. It is highly recommended to use only one tracking method, preferably FirstHive CDP Tag Manager. While there are rare cases where both tracking methods might be used, this approach is discouraged, as FTM can fully meet all your tracking needs on its own. It offers the same benefits as the JS tracker and more.
FirstHive CDP Tag Manager comes with added flexibility, centralized management, and advanced features for enhanced web analytics. Choosing your tracking method will depend on your team’s technical familiarity:
- Technical teams may prefer working with the JS tracker code.
- Marketing teams often prefer managing tracking through the Tag Manager’s interface, which requires less technical expertise.
For users unfamiliar with Tag Manager, the tracker code may seem like a more straightforward option. However, once accustomed to it, FTM provides a more comprehensive, centralized solution.
Tracking with FirstHive CDP Tag Manager
FirstHive CDP Tag Manager is a versatile feature for managing and deploying tracking tags without modifying website code.
- Create custom tags, install third-party tags, and set up triggers and variables in a Tag Manager container for control over when and how tracking occurs.
- Streamline both basic and advanced setups that use multiple tags and custom triggers. Update tracking scripts across different pages without accessing the website’s code.
- The default Tag Manager container is preconfigured with the same tracking coverage as the standard FirstHive CDP JS tracker, so you do not need both methods.
- Includes a predefined FirstHive Analytics Tag, which allows you to track common actions like page views, events, and goals without writing custom code.
- Preview and debug your Tag Manager setup before publishing to your website.
Using FirstHive CDP Tag Manager provides an organized and centralized approach that simplifies updates and adjustments.
Tracking with FirstHive CDP JS
The FirstHive CDP JS tracker is a piece of JavaScript code embedded directly into your website’s HTML. This method is commonly used when applying the same tracking script across all pages without requiring dynamic changes or conditions.
- Collects data on user interactions, such as page views and events.
- Can be extended and customized to track specific events and configure parameters like User IDs.
- Custom JavaScript functions can interact with the JS tracker for more granular tracking.
- Works for detailed tracking on any type of website or app, including ecommerce sites and media platforms.
- Straightforward to implement: simply add the tracking snippet to your website’s HTML.
- Updates and configurations are managed directly in the site’s code base, giving more control for advanced customization.
Dual Tracking with FirstHive CDP JS and Tag Manager
Note: It is not recommended to use both the JS tracker code and FirstHive CDP Tag Manager at the same time. Doing so can cause conflicts in execution timing, leading to incomplete tracking or data discrepancies.
However, in the unlikely case where both tracking methods are active, follow these guidelines:
- Ensure the Tag Manager container code is loaded first. Place the container snippet above the JS tracker code in your website.
- In the Tag Manager variable configuration, disable these options:
- Register as default tracker
- Bundle Tracker
- Plan and coordinate carefully which tracking method handles specific events. Avoid overlapping configurations.
- Use Tag Manager’s debugging tool to test and verify that your tags, triggers, and variables work correctly.