1 of 25

Web App Metrics

with

Google Analytics

Romain Vialard

Product Manager, Revevol - Google Developer Expert

2 of 25

YetAnotherMailMerge

An example with...

3 of 25

Email campaigns with Gmail and Google Sheets

Key numbers

Total number of installations: 600K+

Monthly Active Users: 80K+

Monthly nb of emails sent: 40M+

Preview of YAMM interface

4 of 25

Analytics set-up

5 of 25

Usage - what should we track?

6 of 25

Google Analytics - from web sites to web apps

On web sites you mainly track page views

On web apps you mainly track events

7 of 25

Compare usage month-over-month

Campaigns

Emails sent

Emails sent / campaign

8 of 25

Many reports available: eg. Geo

By emails sent

… or by users

9 of 25

Sending events to Google Analytics 1/3

ga('send', 'event', 'Add-on installed', 'First campaign sent');

ga('send', {

hitType: 'event',

eventCategory: 'Add-on installed',

eventAction: 'First campaign sent'

});

All parameters available when sending data to GA

10 of 25

Sending events to Google Analytics 2/3

ga('send', {

hitType:'event',

eventCategory:'Email_Sent',

eventAction:'Standard',

eventLabel:'',

eventValue:DATA.nbOfEmailsSent,

dimension5:DATA.trackEmail,

dimension6:(DATA.chosenAttachmentColumn) ? 'true' :'false',

dimension7:DATA.selectedDraftSize,

dimension9:DATA.overallMXStatus,

dimension10:DATA.spf_found,

dimension13:DATA.selectedDraftId,

dimension15:DATA.templateHasMarkers,

metric1:DATA.nbOfEmailsSent,

metric2:DATA.nbOfRecipients

});

This send command uses custom dimensions & metrics fields that we will see later on

11 of 25

Sending events to Google Analytics 2/3

function google_analytics() {

var payload = {};

payload.v = '1'; // version

payload.tid = 'UA-88349571-1'; // Tracking ID

payload.cid = Session.getTemporaryActiveUserKey(); // Client ID (cookie)

payload.z = Math.floor(Math.random()*10E7); // Cache Buster

payload.t = 'event';

payload.ec = 'Campaign';

payload.ea = 'Email sent';

payload.el = '';

var options = {

'method' : 'post',

'payload' : payload

};

UrlFetchApp.fetch('https://ssl.google-analytics.com/collect', options);

}

Sending events from server side with UrlFetch

12 of 25

Track user growth & behavior

13 of 25

User growth / Monthly Active Users (MAU)

+38%

Monthly Active Users �between January & September 2016

14 of 25

See all actions for a single user...

User install the app

Lists recipients

Start sending emails

… and reach free quota

15 of 25

… or monitor common behavior

30% install but don’t do anything after

16 of 25

Client vs User ID

A unique identifier

In order for Google Analytics to determine that two distinct hits belong to the same user, a unique identifier, associated with that particular user, must be sent with each hit.

Visits and user are associated

The analytics.js library accomplishes this via the client ID field, a unique, randomly generated string that gets stored in the browser’s cookies, so subsequent visits to the same site can be associated with the same user.

Identification across sessions

Using cookies allows analytics.js to identify unique users across browsing sessions, but it cannot identify unique users across different browsers or devices.

Client ID

User ID

Identification across devices

The User ID lets you associate engagement data from multiple devices and different sessions with unique IDs.

More accurate user count

Each unique User ID is considered to be a unique user in Google Analytics, so you get a more accurate user count in your reports.

Client ID vs User ID

While Client ID is usually automatically generated by Google Analytics, the User ID needs to be generated on server side, by you.

17 of 25

Issue specific to Apps Script:

Cookies aren’t persistent. The Google Analytics cookie will be recreated each time a user re-opens your dialog or sidebar, with a new client ID every time.

�G Suite Developers Blog:

Google Apps Script: Tracking add-on usage with Google Analytics

18 of 25

Feed Google Analytics �with your own attributes

19 of 25

Custom dimensions & metrics

Include non-standard data in your reports

Custom dimensions and custom metrics are like default dimensions and metrics in your Analytics account, except you create them yourself. You can use them to collect and analyze data that Google Analytics doesn't automatically track.

20 of 25

Monitor adoption of your features

63% of users have markers in their template

84% are tracking who opened the emails sent

21 of 25

… over time

In January 2016, 60% of our users were tracking emails sent

Now 84% are using this feature

22 of 25

Tag users with specific attributes

Paying customers represent a growing part of our Active Users

23 of 25

And build custom reports

In Google Analytics we are not allowed to track personally �identifiable information (PII) �such as names, email addresses or billing informations

24 of 25

  • Easy to set up
  • Comes with many default reports
  • Highly customizable (data, reports)
  • Big community (easy to find help online)
  • APIs & exports

Why Analytics for your add-on?

25 of 25