Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Being able to track a website in two separate instances (without duplicating tracking in one instance based on the other) #22230

Open
ffkpisfr opened this issue May 17, 2024 · 0 comments
Labels
Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. To Triage An issue awaiting triage by a Matomo core team member

Comments

@ffkpisfr
Copy link

ffkpisfr commented May 17, 2024

In some cases, websites have a Matomo tracking fired by one instance - let's call it instance A - owned for by a web agency for example.

But clients want to have their own tracking based on their Matomo instance (Instance B).

Today, if I install this tracking, the data is mixed because _paq object is the same for instance A and instance B.

How can we solve this issue without relying on :

/ Add this code below within the Matomo JavaScript tracker code
// Important: the tracker url includes the /matomo.php
var secondaryTrackerUrl = 'https://analytics.example.com/matomo.php';
var secondaryWebsiteId = 77;
// Also send all of the tracking data to this other Matomo server, in website ID 77
_paq.push(['addTracker', secondaryTrackerUrl, secondaryWebsiteId]);

Because this implies that we will depend on somebody else's tagging plan, tracking config, etc.

Thank you.

Frederic

@ffkpisfr ffkpisfr added Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. To Triage An issue awaiting triage by a Matomo core team member labels May 17, 2024
@ffkpisfr ffkpisfr changed the title Being able to track a website in two separate instances (without duplicating tracking in one based instance on the other) Being able to track a website in two separate instances (without duplicating tracking in one instance based on the other) May 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. To Triage An issue awaiting triage by a Matomo core team member
Projects
None yet
Development

No branches or pull requests

1 participant