2

Ad blocking is all the rage. Included in the blocking is analytics and thus Google Analytics.

At some point I will consider switching to (or making) a first-party tracking system for Google Analytics because more and more users will block the normal third-party implementation.

What is the easiest way for me today to measure the number of users which have blocked Google Analytics? I imagine this will be some combination of comparing server access logs with GA or some other scripted feature on my server.

  • 1
    Isn't Google Analytics a JavaScript based thing? I'm no expert but if you have a known object or variable in the analytics script, then have a custom JS script that checks if said object is undefined or not, you should be able to tell if the Analytics script is running. – K4KFH Feb 12 '16 at 4:53
  • @K4KFH Thank you, this looks like the winning solution, just checking if the ga function is defined – William Entriken Feb 12 '16 at 15:03
3

Try installing Piwik analytics locally (rename piwik.js script to some random string like azsdgt.js, so it won't be blocked by any of the adblockers). With proper amount of integration it's much more powerful than Google Analytics. Though you will probably end with having both, because of SEO and adwords...

As of 2019, there is a new method to integrate Google Analytics via the Measurement Protocol. This way the data will be sent directly to google by your web application, without the need to display any scripts to end-user, making this way of gathering data unblockable... However, I must note that implementing that protocol might be not as straightforward as it seems - if you'll just send data to google on every hit, your web app will slow down significantly. To solve performance issues, you'd have to implement some kind of independed queuing mechanism/server, so sending data will be processed independently of the app itself...

  • 1
    I have to add a +1 for piwik, I don't do websites and such but one place I was at was floored by the differences in metrics. – Jim B Dec 11 '15 at 0:58

Not the answer you're looking for? Browse other questions tagged or ask your own question.