Skip to content
[shareaholic app="share_buttons" id="14657658"]
Share this..

Multiple Sites in Piwik

2008 October 22

So I was checking my analytics (piwik of course 😉 ) today and I noticed a lot of folks landing on my page after searching this title, ‘multiple sites piwik’.

Unfortunately they were landing on a page that only briefly discussed that it was a capability of piwik, so I felt alot of users were leaving with a bad taste in their mouths. To make amends Ill do my best to sum up this easy process.

 1. Steps to add additional domains to your piwik analytics.

1. Steps to add additional domains to your piwik analytics.

I’ll assume you have Piwik installed? I used a subdomain ( but that’s not necessary, just nice.

  1. First Off log in as an admin by clicking the link in the upper right hand corner while viewing the initial page.
  2. Under the heading look for the tab marked Sites, and follow through.
  3. Click the line ‘Add a new Site’
  4. Enter Site Name, and primary url in the text boxes that appear
  5. When finished click the small green checkmark.

    After a moment or so the new information should be added as another level in the table.
  6. Click the ‘Show Code’ link in the rightmost column.
  7. Copy the code into the html of your site, and publish to the world.
  8. Open a new window or tab and Visit your site and hit any url that will activate the code you just added.
  9. Back to our Piwik window, Click the ‘Back To Piwik’ link
  10. Select your new site from the drop drop down in the upper right
  11. Finally change the day to the current date to see your results.
    By default, and quite logically, piwik shows yesterday, the last full day of statistics.

That’s it, please comment if there is more you would like me to address.

12 Responses leave one →
  1. Jonathan permalink
    November 7, 2008

    Actually.. the reason its being searched is likely because there is zero documentation on how to use piwik with multiple domains with a single IDSITE.

    Lets say someone has 100 websites.. piwik allows you to drop in upto 200 domains into a single idsite so that you can add that code to all the sites and be able to get an overview of them all from one page. Useful right?

    Problem is.. Piwik only displays the page names.. and not the domain names of where the traffic is being generated. in the javascript code doc it talks about using the action_name to show page titles.. but what we really need is to see urls.

  2. Eddie permalink*
    December 20, 2008

    @Jonathan – Sorry for the delay.

    It would be easy enough to insert


    in order to get the current domain.

    Alternately you can see the full url by using



    Insert into the piwik_action_name = ”; parameter…

    piwik_action_name = location.href;

    Hope that helps anyone in your situation out. – EW

  3. Marcadr permalink
    June 6, 2009

    Thanks Eddie, you saved me a huge amount of time!! 🙂

    There aren’t many stats program that have this feature and it should be actually much easier to implement.. I’m sure it would bring a lot more people to Piwik.

    Thanks again!

  4. eawQuint permalink
    July 8, 2009

    I would like to find a way
    to view the unique visitors
    to a dozen or so sites
    on one page
    in chart form.

    Ideally, it would be on a dozen graphs, or it could be on one chart.

    Can Piwik do this?

  5. Eddie permalink*
    July 8, 2009


    Great question. I guess my answer depends on your structure.

    Piwik allows you to specify multiple domains to be considered as one site. (example :,, in which case you could view all data (unique visitors, content, times ,etc ) on one chart.

    If they are unique sites in terms of content, then you obviously don’t want to go down that road. But Piwik offers a great API and export abilities, so you could easily build a widget to do this, or export the data to Excel and make an aggregate graph there.

  6. July 22, 2009

    I am very new to piwik.I really need your help.
    Can you please explain where I need to change for full URL in reports as well as API?


  7. October 30, 2010

    Im going to add this to our website. I think this will be just the tool we’ve been looking for. Thanks for your great write-up!

  8. June 22, 2011

    Thanks for the info, I am looking to move from google to piwik and this information is helpful.

  9. eddie permalink*
    July 14, 2011


    I mentioned this on my other Piwik post, but I would suggest you look into OWA Open Web Analytics.

    Very powerful analytic features including visualizations and site-paths.

    The layout is also more akin to Google Analytics, making for an easy switch.

  10. December 14, 2013

    Hi Edward,

    Smart move on your part to actually offer a how-to on using multiple sites in Piwik after noticing the search results!

    In fact, though the first comment here is over 5 years old, today I’ve come across this page looking for the same information. It was only after landing here that I notice Piwik had finally included some documentation in their faq section ( and

    Anyway, many thanks, Edward.

Trackbacks and Pingbacks

  1. Open source project Piwik puts Google Analytics on notice | Edward A. Webb (.com)
  2. how to use Piwik analytics in CakePHP sites | Edward A. Webb (.com)

Leave a Reply

Note: You can use basic XHTML in your comments. Your email address will never be published.

Subscribe to this comment feed via RSS