Protect user privacy by using Matomo, dumping Google Analytics?

Hi! Coincidentally I just came across this older Discourse post of mine yesterday and a good comparison of Matomo vs GA at about the same time. (I didn’t find an answer to your question that I was happy with when you first asked and I originally looked.)

“The difference between cloud hosting Matomo Analytics vs Google Analytics is that when you choose Matomo, we acknowledge you own the data and we have no right to access it. This means we can’t on-sell it to third-parties, we can’t claim ownership of it, you can export your data at anytime (how awesome is that!) and you can migrate between cloud hosting and hosting on-premise for ultimate flexibility whenever you want.”

Why Matomo is a serious alternative to Google Analytics 360

And a comparison table: Learn about the differences between Matomo Analytics vs Google Analytics 360

GA is a pretty fundamental tool for a huge portion of our customer base, many don’t have the choice, so we won’t remove

I’m not sure where this extreme suggestion to remove it comes from!

a huge portion of our customer base, many don’t have the choice

I’d like to point out that Discourse itself isn’t offering analytics choice yet. Discourse is biased toward one analytics supplier, somewhat unpopular for its privacy-practices. Why is this necessary or even desirable?

I’d also like to respond to a previous post that suggested Matomo was a problem because it was written in php.

Websites interface with Google Analytics via Javascript tracking code. They can do so identically with javascript and a Matomo hosted solution: either that offered by Matomo, or their own instance of Matomo on their own server. See Matomo javascript

Discourse has no problem clearly declaring various php-based software on this page is integrated. So why raise php as a barrier for offering a choice for Discourse users to use open-source analytics?

Also, here’s an important reason self-hosted Matomo on your own server is beneficial. Google Analytics javascript is now widely blocked by anti-tracking browser plugins. Because Matomo is just js on your own website, you can easily configure it so it won’t be blocked and you get reliable analytics.

Can the way that GA code is inserted simply be generalized? I am thinking this could be as simple as a text box that is initialized with GA code that could be replaced, so that the user can simply supply the javascript analytics tracking code they want - be it Matomo or any other analytics software? Discourse seems to be wonderfully configurable in so many ways. User-definition of analytics javascript seems like a straight forward flexibility extension.

I would suggest that Matomo support should be added to Discourse as it is also open source software, not part of a monopoly trying to control the internet. Matomo allows a great deal of user customization and total control of data as Discourse does. Discourse should add support for Matomo because doing so supports the greater community of open source software, and user control of data. Discourse should add support for Matomo on greater principles.

I’m no ruby coder but I may take a stab at this if nobody else does, as it doesn’t seem to be a big project.

cheers,
Brett