Late last year, a few of the Digital Performance analysts in DWP started a project that aimed to answer the question ‘what’s the best way to implement Google Analytics on our services’. We started the project because we realised that, as the team’s expertise had developed over the previous couple of years, so had the way we implemented GA on the services we support.
This had led to the various services we support being tagged quite differently. That in turn meant comparing services was difficult, as they might be recording similar actions differently. It also meant that if one of the team needed to do some analysis on a property they hadn’t set up, they had to learn the idiosyncrasies of how GA had been implemented on that service. And when we reviewed the GA implementation on all our services, we saw that most services that were tagged in a way that didn’t let us do certain kinds of analysis.
We also realised we were spending significant amounts of time working with services to determine what we should tag on each page. This meant we were effectively spending time creating a measurement framework each time a new service was set up.
Another issue was that if we identified a need to tag something that hadn’t originally been tagged we had to work with the Developers to get the tagging code in place, then wait to get enough visits to be able to analyse it.
So we defined the objectives for our project as:
- Identify or develop the best way to tag different kinds of components on services (for example, radio buttons, validation errors, and outbound links). The ‘best’ way is that which allows us to answer all the questions we think we might need to answer about users’ interaction with a component, or the best compromise where this isn’t possible
- Develop a standard GA implementation specification that could be used for all new services, with the least amount of modification required. This should reduce the amount of time we spend developing bespoke implementations, and ensure we have the data to answer questions when they come up, not a few weeks later.
While that might sound simple, it took a lot of head scratching, workshops, experiments, and hacks to create what we felt was a decent starting point. We’ve produced a technical document setting out how GA will be implemented on DWP services from now on, but I wanted to share some of the kinds of analysis this allows us to do, to raise awareness of the kinds of things we’re now able to provide for teams, focusing more on the value of the analysis rather than the technical side. I’m going to do that through a series of posts on this blog (starting with radio buttons). If you’re a Digital Performance Analyst/Web Analyst and you’re interested in the more technical side of this, see my post on the gov.uk data blog.