How can we track multiple website using the same Piwik tracking code


I have two different website and wanted to track both of them using the same PIWIK PRO tracking code.

I have injected the Piwik pro tracking code on both the website using adobe launch and given both website url in the data collection under basic info.

Right now for one of the website its working for other website its not working.

Any help on this?

What can you see in the browser’s console on the other website? Does the tag manager debug mode work?

In general, such setup should work without any issues.


Debug mode is opening for only one website.

Note: The hostname of both the website is different. Should we use different tracking code for both the website or one tracking code is enough to track both the website?


You can use same tracking code.

So, clearly the product isn’t installed correctly. Do you see any errors in the console? Can you maybe share the url?

Sorry i can’t share the URL as this requires login credential.

Do we need to give all the URLs where we want to track in the basic info under the data collection?

As i see if i don’t give any URL in the basic info under the data collection then also tracking is happening then what’s the need of this?

There are a few situations where those urls are in use:

  • excluding each other from the outlinks report
  • figuring out the URL for the tag manager debug mode
  • " Collect data only from known sites" setting

But as you observed, those entries are not needed to make the tracking work by default.

Can you confirm that the installation code was properly installed on this website?

Actually code was injected into the website through adobe launch and i saw that rule is getting triggered on both the website.

If opening the website with a ?stg_debug param doesn’t open the debug mode, then most likely the container code wasn’t properly triggered by adobe launch.

ok thanks a lot for the update. Will check on this.

One more question- How to stop multiple events getting triggered on the click of the social button. I mean to say when i click everytime on the social button, no of events increment.

It’s a question for a separate thread. In general, there’s nothing bad about sending same event multiple times. On the reports, you should be able to compare no. of events with no. of unique events. Limiting this kind of behaviour can be achieved with custom code that would simply block sending the event once again (you can store the state in localstorage /cookies if you want to preserve it between page views or just in javascript object if it concerns the same page view).

Thank you. Here i am talking about the custom event not page view. I am getting multiple event call when i clicked on facebook button. Every time same click event gets incremented by one.