# Huge difference between Matomo or GA on piwik pro

**URL:** <https://community.piwik.pro/t/huge-difference-between-matomo-or-ga-on-piwik-pro/1063>\
**Category:** Data collection and tags\
**Created:** [October 3, 2022, 9:47am UTC](https://community.piwik.pro/t/huge-difference-between-matomo-or-ga-on-piwik-pro/1063 "2022-10-03T09:47:28Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![bastien\_g](https://dub1.discourse-cdn.com/flex005/user_avatar/community.piwik.pro/bastien_g/32/804_2.png) [@bastien\_g](https://community.piwik.pro/u/bastien_g)\
**Post date:** [October 3, 2022, 9:47am UTC](https://community.piwik.pro/t/huge-difference-between-matomo-or-ga-on-piwik-pro/1063/1 "2022-10-03T09:47:28Z")

</div>

Hello,

I don’t know what I may have missed in the installation but I can’t manage to recover all my visits & my events.

With a simultaneous Matomo & Google Analytics installation I have huge differences.  
(For test the best tools)

My configuration is :

**GTM tag with trigger on All Pages :**

```auto
<script type="text/javascript">
(function(window, document, dataLayerName, id) {
window[dataLayerName]=window[dataLayerName]||[],window[dataLayerName].push({start:(new Date).getTime(),event:"stg.start"});var scripts=document.getElementsByTagName('script')[0],tags=document.createElement('script');
function stgCreateCookie(a,b,c){var d="";if(c){var e=new Date;e.setTime(e.getTime()+24*c*60*60*1e3),d="; expires="+e.toUTCString()}document.cookie=a+"="+b+d+"; path=/"}
var isStgDebug=(window.location.href.match("stg_debug")||document.cookie.match("stg_debug"))&&!window.location.href.match("stg_disable_debug");stgCreateCookie("stg_debug",isStgDebug?1:"",isStgDebug?14:-1);
var qP=[];dataLayerName!=="dataLayer"&&qP.push("data_layer_name="+dataLayerName),isStgDebug&&qP.push("stg_debug");var qPString=qP.length>0?("?"+qP.join("&")):"";
tags.async=!0,tags.src="https://xxxxxxxx.containers.piwik.pro/"+id+".js"+qPString,scripts.parentNode.insertBefore(tags,scripts);
!function(a,n,i){a[n]=a[n]||{};for(var c=0;c<i.length;c++)!function(i){a[n][i]=a[n][i]||{},a[n][i].api=a[n][i].api||function(){var a=[].slice.call(arguments,0);"string"==typeof a[0]&&window[dataLayerName].push({event:n+"."+i+":"+a[0],parameters:[].slice.call(arguments,1)})}}(i[c])}(window,"ppms",["tm","cm"]);
})(window, document, 'dataLayer', '1ccd73d4-4fb3-411c-8e9d-f156424c0769');
</script>

```

Then  
**Piwik PRO Tag manager:**  
Page viewed on all pages.

Then  
**Piwik PRO - Events :** custom event with {{category}}{{action}}{{label}}

In parallel on my GTM I also send events to Matomo:

`_paq.push(['trackEvent', {{DL - VAR - eventCategory}}, {{DL - VAR - eventAction}}, {{Event}}, {{DL - VAR - eventValue}}, {dimension1: {{DL - VAR - eventLabel}},dimension2: {{DL - VAR - utm_campaign}},dimension3: {{Cookie - ClientID GA}}}]);`

I don’t really understand what can be a problem because Piwik Pro records 1/4 of my visits.

Please can you help me ?

Thank you 🙂

---

<div class="post-metadata">

**Author:** ![Maciej\_Kowcun](https://dub1.discourse-cdn.com/flex005/user_avatar/community.piwik.pro/maciej_kowcun/32/787_2.png) [@Maciej\_Kowcun](https://community.piwik.pro/u/Maciej_Kowcun)\
**Post date:** [October 4, 2022, 11:47am UTC](https://community.piwik.pro/t/huge-difference-between-matomo-or-ga-on-piwik-pro/1063/2 "2022-10-04T11:47:28Z")

</div>

Hi Bastien,

Please verify if Piwik PRO and Matomo useses `_paq.push()`. If so, they will interfere with each other. You can find more information in [this](https://help.piwik.pro/support/questions/can-i-use-piwik-pro-and-matomo-at-the-same-time/) article.

Also, data layer names have to be unique (the tools can interfere with each other when names are the same). [This](https://developers.piwik.pro/en/latest/tag_manager/data_layer_name.html) article might be helpful.

Maciej

---

<div class="post-metadata">

**Author:** ![bastien\_g](https://dub1.discourse-cdn.com/flex005/user_avatar/community.piwik.pro/bastien_g/32/804_2.png) [@bastien\_g](https://community.piwik.pro/u/bastien_g)\
**Post date:** [October 5, 2022, 2:11pm UTC](https://community.piwik.pro/t/huge-difference-between-matomo-or-ga-on-piwik-pro/1063/3 "2022-10-05T14:11:37Z")

</div>

> [@Maciej\_Kowcun](#):
>
> Salut Bastien,
> 
> Veuillez vérifier si Piwik PRO et Matomo utilisent ces fichiers `_paq.push()` . Si c’est le cas, ils vont interférer les uns avec les autres. Vous pouvez trouver plus d’informations dans [cet](https://help.piwik.pro/support/questions/can-i-use-piwik-pro-and-matomo-at-the-same-time/?pk_vid=166445205912e9a2166496539312e9a2) article.
> 
> De plus, les noms des couches de données doivent être uniques (les outils peuvent interférer les uns avec les autres lorsque les noms sont identiques). [Cet](https://developers.piwik.pro/en/latest/tag_manager/data_layer_name.html) article pourrait être utile.
> 
> Maciej

Thank you for you’r response and this article !  
They uses \_paq.push together.  
This is the reason for the problem.  
I was able to fix the problem, it seems to work. 💪
