Migration Guide: From Google Tag Manager to Matomo Tag Manager

Google Tag Manager is a powerful tool that allows you to manage all your website tags from a centralized panel. However, for data privacy, server-side control, and SEO-focused analytics, many users prefer to migrate to Matomo Tag Manager. Matomo Tag Manager offers a tag management system similar to Google Tag Manager while allowing you to manage all your tags, triggers, and variables securely and centrally. In this guide, you will learn step by step how to migrate your existing Google Tag Manager configurations to Matomo Tag Manager.

WhatsApp

Why Migrate to Matomo Tag Manager?

Migrating your website’s tag management from Google Tag Manager to Matomo Tag Manager enhances data privacy and allows you to perform analytics and SEO tracking through a more centralized system.

While Matomo Tag Manager lets you control user behavior and tags on your own server, Google Tag Manager is cloud-based and may have certain data privacy limitations.

The table below highlights the key differences between Google Tag Manager and Matomo Tag Manager:

Feature
 
Google Tag ManagerMatomo Tag Manager
Installation
 
Cloud-based, quick integrationServer-side or cloud, full control
Data Privacy
 
Stored on Google serversStored on your own server
SEO and Analytics Control
 
Basic data tracking, limited analyticsIn-depth SEO-focused data and custom reports
Tag, Trigger, and Variable Management
 
Centralized panel, popular integrationsCentralized panel, customizable and API-supported
Testing and Preview
 
Preview mode availableAdvanced testing and version control available

These differences make Matomo Tag Manager a more advantageous option, especially for businesses that prioritize data privacy, server-side control, and SEO-focused analytics.

Migration Process from GTM to MTM

Tags, triggers, and variables created in Google Tag Manager (GTM) cannot be transferred to Matomo Tag Manager (MTM) with a single click. Therefore, the migration process must be done manually. Each tag, trigger, and variable needs to be recreated individually in the MTM panel.

Although GTM and MTM share similar building blocks, some features are not exactly the same. For example, tag types and trigger options are mostly comparable, but variable management and testing/preview functionalities may differ between platforms.

The table below compares the core building blocks of GTM and MTM side by side:

Feature
 
Google Tag Manager (GTM)Matomo Tag Manager (MTM)
Tag Management
 
Ready-made templates and popular integrationsCustomizable tags, API-supported
Triggers
 
Click, page view, form submission, etc.Similar trigger types with additional testing options
Variables
 
Default and custom variablesDefault, custom, and data layer-supported variables
Testing & Preview
 
Preview mode availableAdvanced preview and version control available
Data Storage
 
On Google serversOn your own server with full data privacy control

This structure allows you to manually migrate each tag to MTM while leveraging similar building blocks to create a fast and error-free workflow during the migration process.

Migration Examples: From GTM to MTM

Providing examples of commonly used tags and triggers during the migration from GTM to MTM helps make the process easier to understand. Below is a step-by-step guide with illustrative instructions.

Scroll Tracking

  • In GTM:
    Tags are created using a Scroll Depth Trigger, firing at specific points such as 25%, 50%, 75%, and 100% of the page.

  • In MTM:
    A similar trigger type, Scroll Depth Trigger, is selected, and the same percentages and firing conditions are manually configured.

  • Benefit:
    Accurately analyze user engagement and page content performance.

Custom HTML Usage

  • In GTM: A Custom HTML Tag is added for custom JavaScript or HTML code.

  • In MTM: The same code is added using Custom Tag or Custom HTML in the MTM panel and assigned a trigger.

  • Benefit: Provides flexibility for custom tracking, third-party integrations, or adding scripts.

Using JavaScript Variables

  • In GTM: A JavaScript Variable is defined and used in tags.

  • In MTM: A Custom JavaScript Variable is added to dynamically use the same value across tags.

  • Benefit: Automatically updates all tags when the variable value changes.

Form Tracking

  • In GTM: Forms are tracked using a Form Submission Trigger.

  • In MTM: A Form Submission Trigger is created, specifying which forms to track and the triggering conditions.

  • Benefit: Simplifies conversion and user interaction analysis.

Page View Tracking

  • In GTM: Each page load is tracked using a Page View Trigger.

  • In MTM: A Page View Trigger is added, with triggering based on page URL, path, or title.

  • Benefit: Essential for page-level visitor analysis and SEO reporting.

Hotjar Implementation

  • In GTM: Hotjar Tracking Code is added via a Custom HTML Tag and assigned a trigger.

  • In MTM: Hotjar script is added as a Custom HTML Tag in MTM and linked to a trigger.

  • Benefit: Enables monitoring of user experience and heatmap analytics directly in the Matomo panel.

Son Güncelleme: 04/11/2025

Our Officess

Dublin

20 Harcourt Street, Dublin 2, D02 H364

+353 (87) 198 6950 

[email protected]

İstanbul

GOSB Teknopark Hi-Tech Bina 3.Kat
B3 Gebze - KOCAELİ

+90 262 678 8872 

[email protected]

Frankfurt

Bleichstr. 26 64283 Darmstadt
Deutschland

+49 (0) 6151 – 492 70 23 

[email protected]