Open dalgard opened 2 years ago
Additionally – as have been argued by plenty of people – there's simply no place for Google Analytics inside a browser extension.
Concretely, the standard should be something like this: https://github.com/stefanXO/Tab-Manager-Plus/blob/master/PRIVACY.md
Additionally – as have been argued by plenty of people – there's simply no place for Google Analytics inside a browser extension.
Partially related:
@dalgard I definitely see your point, and agree with your concerns. This was a quick chrome extension I hacked together for myself back in 2013, and it's only been very minimally updated since (last update was in 2018).
I can't remember my exact motivations, but I think I added Google Analytics so that I could see if/how often the extension was being used, and which features within the extension are being used; with the goal/theory to be understanding what parts are useful, and what parts aren't.
While I haven't exactly done much development/refinement on this extension making use of that, it's a feature I still value having. I'm not particularly wed to using Google Analytics for any reason other than that's what I was familiar with at the time. If there are alternative/better privacy preserving options these days, that would still allow me to track (anonymised) usage + which parts of the extension are used, I would definitely be open to hearing more about them.
I'm also open to adding this analytics as a configurable option, though right now it's more effort than I have time/energy to spend on this extension. There is currently no options page, so I would need to build that in first (see #5). At some point 'soonish' i'll need to update the extension for Manifest v3 (see #13), which I think might restrict/remove the ability for GA to work anyway; but at least at that point, I might have the focus/bandwidth to implement the options page/etc.
A few references for future me:
Caution: This page was migrated directly from the Manifest V2 documentation set. It has not yet been validated for compliance with Manifest V3.
RE: the inclusion of Google Analytics, there is also a need to update from the old 'Universal Analytics' to the new 'Google Analytics 4', which depending on the effort involved, may impact on my decision forward here:
Google Analytics 4 has replaced Universal Analytics
[GA4] Make the switch to Google Analytics 4
Google Analytics 4 has replaced Universal Analytics. Starting July 1, 2023, standard Universal Analytics properties stopped processing data. (360 Universal Analytics properties with a current order will receive a one-time processing extension ending on July 1, 2024.)
Starting March 2023: If you didn't manually migrate your active standard Universal Analytics property to a new Google Analytics 4 property and didn't opt out of an automatic property creation, we created a Google Analytics 4 property on your behalf. Automatically created Google Analytics 4 properties reuse existing site tags whenever possible.
Starting July 1, 2023: Standard Universal Analytics properties stopped processing hits, including standard properties in accounts that also contain 360 properties. Some properties continued to process data for a short period after this as we staged the shutdown of Universal Analytics. You'll be able to access your previously processed data in your Universal Analytics property until July 1, 2024.
[UA→GA4] How to check whether you have Universal Analytics or Google Analytics 4 (GA4)
Universal Analytics property IDs start with UA and end with a number (UA-XXXXXXXXX-1).
Google Analytics 4 property IDs have only numbers (XXXXXXXXX).
Tutorial: Google analytics
Warning: You're viewing the deprecated Manifest V2 version of this article. See Manifest V3 - Using Google Analytics 4 for the MV3 equivalent. The Chrome Web Store no longer accepts Manifest V2 extensions. Follow the Manifest V3 Migration guide to convert your extension to Manifest V3.
Use Google Analytics 4
This tutorial demonstrates how to track the usage of your extension using Google Analytics. You can find a working Google Analytics 4 sample on Github, where
google-analytics.js
includes all the Google Analytics related code.
Using the Google Analytics Measurement Protocol Since Manifest V3, Chrome Extensions are not allowed to execute remote hosted code.
This means you have to use the Google Analytics Measurement Protocol for tracking extension events. The Measurement Protocol lets you send events directly to Google Analytics servers via HTTP requests. A benefit of this approach is that it lets you send analytics events from everywhere in your extension, including your service worker.
Caution: Using the Measurement Protocol means that some information, such as geolocation, will not be included.
Announcement: Chrome Web Store now supports Google Analytics 4
Dear Developer,
We're excited to announce that the Chrome Web Store Developer Dashboard now supports Google Analytics 4 (GA4). We've simplified setting up Google Analytics with a new flow in the Developer Dashboard.
Access management for group publishers is also now more straightforward. For individuals in group publishers, Chrome Web Store ensures that all members of the group publisher can access the Google Analytics dashboard for that item. Members removed from the group publisher will no longer be able to view the analytics associated with the items in the group publisher.
If you previously used Google Universal Analytics to track your store listing activity, you will need to take action by July 1, 2023 to ensure that you continue receiving data about your store listing.
A button has been added to the Developer Dashboard to set up GA4 tracking for your Chrome Web Store item. The button starts a flow that will guide you through the creation process.
Until July 1, 2023, you'll be able to use both Universal Analytics and GA4 simultaneously. On that date, support for Universal Analytics will be removed from the Developer Dashboard.
Thank you for your cooperation and for your participation in the Chrome extension ecosystem.
- The Google Chrome Web Store team
Some high level stats/reports from the old Google Analytics tag:
(obviously heavily biased since it's a Chrome Extension)
(Stopped showing them once we got to ~1k sessions per country)
From that high level overview, it's interesting how many users/sessions are listed, vs the relatively small number of actual events tracked. That data will be somewhat skewed as I believe views of the Chrome Extension Store page are also tracked within that, so I would need to slice the data by source to get a more accurate number of 'actual users' vs 'events', but at least from that high level view of data, it seems to imply that (assuming all events logged correctly) the extension doesn't have a very high number of actual usages over the years, and that apparently newWindowWithCurrentAndTabsToRight
is MUCH more popular than newWindowWithTabsToRight
(which to be fair, is probably my more used option as well).
Not sure if I did this slice properly.. but basically filtered for users who landed on /_generated_background_page.html
as a proxy for 'actual extension user' (rather than just a random extension store viewer/etc), which makes it look more like this:
New Users Per Day:
Users Per Day:
Sessions Per Day:
The
"tabs"
permission is no longer necessary, as long as you don't need the specific urls of tabs, among other things.Please remove this permission from the manifest as soon as possible, so your extension can be installed completely without any worries about potential privacy violations in this or future versions. It's awesome that you link this extension directly to GitHub – I wish everyone would follow your example in this respect. With this tiny adjustment, noone in the future would need to spend time checking through your code, just to make sure that everything is above board – which, of course, it totally is 🙂
Additionally – as have been argued by plenty of people – there's simply no place for Google Analytics inside a browser extension. I understand that GA is standard for most web development, but when it comes to the private browser behavior that any single individual chooses to install on their local machine, any kind of uploaded data should be specifically declarered and accepted by the user before any cloud data collection 🙏