It's really fun using Google Analytics. You see how many (or how few) people have visited your site, where they looked, how much time they spent and much more fun stuff.

But it comes at a significant cost to your users: user privacy.

Here are some alternatives to using Google Analytics that will work for your Ghost blog.

Private information that Google Analytics collects about users

Google's tracking code, which you have to install on your website in order to use Google Analytics, sends information back to Google about the browser that has landed on the website.

According to Google's own website, Google collects:

  • Details about the browser and the computer making the request, icnluding the hostname, browser type, referrer and language
  • Detailed system information, including Java and Flash support and screen resolution
  • Information about how the user spends time on the page ("session information") and ad campaign information
  • Advertising information, via the DoubleClick cookie

Can Google Analytics identify you?

It doesn't explicitly say it can. But there are a few ways it does.

Firstly, Google Analytics can identify individual users by IP address combined with other specific information it collects, hashing them into an identity. Say you visit one website and are tracked. You then visit another website. Both requests come from browsers with similar characteristics, so they're probably from the same person.

Secondly, if you're logged in to a Chrome browser as yourself, everything you do in that browser is linked to your identity.

Finally, the demographics tab in Google Analytics shows a TON of information it could be collecting. We haven't enabled those yet for our blog Discover Discomfort. But look at the stuff we could be collecting!

Quick tracking me! What ad blockers or browsers block Google Analytics?

There are a number of ways to block Google Analytics from working, if you're interested.

Firstly, you can use a privacy-focused browser. Firefox is heavily privacy-focused. Firefox Focus (one of the mobile options) is even more privacy focused, and is a popular choice on your browser. By default, both these browsers block all scripts and ads. A quick google for privacy-focused browsers brings up a number of options, but Firefox is probably your fastest, most reliable bet.

Secondly, you can block scripts with an alternative to AdBlock. Try AdGuard or uBlock Origin, and make sure you configure them to block tracking. I really like AdGuard, but that's just because I happy to install it (because AdBlock kept crashing, actually); uBlock Origin is a favourite for privacy types.

Finally, you can block scripts with a dedicated blocker. Try ScriptSafe for example. The main problem with this approach is that there are lots of scripts that do benign things, like let forms work, and you'd be preventing any of those from working. Webpages might not display or function as expected.

How to protect user privacy as website administrator

If you manage a website, consider using a non-tracking alternative to Google Analytics. I'm going to be experimenting with these on and see what they do.

The following are the ones I'll try, in order of how awesome they are. Yes, my favourite is GoAccess, as it doesn't require any tracking codes. If you want to use rich behavioural tracking, use Matomo. Fathom looks fine, but I wouldn't recommend Simple Analytics.

My personal recommendation would be to use GoAccess combined with Matomo.

GoAccess - live, tracking-free server-side analytics

GoAccess is how tracking originally used to be.

If you run a web server, you know what pages your web server is sending out. You get the requests directly! As a result, you have all the information on hand already, and all you have to do is serve it up visually.

The main caveat is you have to have your own web server to run this, and it has to be one where you can install software. We run all our websites on DigitalOcean so this isn't a problem for us. If you use a host (like HostGator), or you use a managed service like SquareSpace, you won't be able to use this.

Matomo - Liberating Web Analytics

Here's a detailed guide for installing Matomo for Ghost on an Ubuntu server.

Matomo is similar to Fathom (below). They have a standalone analytics service that you can either run self-hosted for free, or let them host for $9 a month (and up). Rather than try to offer everything in one page, like Fathom does, they offer pretty rich analytics, including

  • Media Analytics: Analyse how your audience watches and interacts with video
  • Content Interactions: clicks around the web pages
  • Transitions: analyse the previous and following actions of visitors for each page
  • "Row Evolution": see how any metric ("Row") in your report changes over time
  • Conversion Optimization: heat-maps, session recordings, funnels, A/B testing and other features
  • Visitor Profiles: a full lifetime journey of an individual visitor to the website
  • SEO analytics: unbiased search engine reporting, integrations with a number of search engines, eliminating "keyword not defined" in your reports. I don't know if GA is biased, but this makes it seem so!
  • Ecommerce goals tracking (sales)
  • Campaign Tracking: UTM codes and other parameters
  • Roll-Up Reporting: combine reporting from multiple websites

A principal differentiator is that they have a really need web-based installation process.

It used to be called Piwik, I don't know why they haven't updated their graphics

One downside of Matomo is that unless you self-host, it will be blocked by ad blockers by default. This is true of any public system, including Fathom. So you have to self-host for it to work best.

Open Web Analytics - open-source self-hosted analytics - modern open source self-hosted analytics

These guys have a free forever self-hosted plan, and I think it looks pretty good.

Fathom Analytics - Simple, useful stats without tracking or storing user data.

Fathom was set up in response to Google Analytics. They specifically claim to

  • Offer simple traffic insights
  • Not store personal user information
  • Offer simple setup
  • Be GDPR compliant

I'm really tempted, in particular, by the assertion that it's way simpler than Google Analytics.

Get all the information you need about how your website is performing from a single screen—there aren’t dozens of pages of reports to dig through. And it’s all built on modern, cloud-based technology, giving you simple, reliable and trustworthy details about how people are using your website. (from their main webpage)

Fathom is either free if it's self-hosted, or starts at $14/mo for up to 100K visitors per month.

The main downsides to Fathom is that the installation process is a little scary if you're using the self-hosted version.

Simple Analytics - Analytics without tracking

I first found Simple Analytics in a post on Show HN. The creator was filling a gap he perceived to be in the market. The discussion was pretty interesting. Unfortunately, I can't recommend this.

It has a really clean dashboard (see their demo one), showing only the basics. In fact, they only show page views, referrers, top pages, and screen sizes. There's no granularity about referrers for each page, for example. This isn't enough granularity for me, so I doubt it is for others.

There's no self-hosted or free option, and unlike Fathom, it's not open-source (you can find Fathom on Github). Pricing is at $9 a month, with no free tier. This means that you have to pay to send information to the website admin, which is fine if you trust him, but there's no guarantee he'll always be the one in charge. Or, in fact, that he is now. No offence Adrian, but what if you're a front for the Chinese Communist Party? Sounds crazy, but it's the kind of thing they do with their "free" VPN software around the internet.