Brief Google Analytics Update

Leanpub
Leanpub
Feb 22, 2017 · 1 min read

by Len Epp

published Sep 08, 2015

Here’s some up-to-date info about using Google Analytics with Leanpub. For an awesome post explaining how to use Google Analytics, check out this post by Leanpub author Visnja Zeljeznjak.

Page Views

A page view is sent to Google Analytics from Leanpub when a user lands on:

  1. Book landing page (/books/:slug)
  2. Bundle landing page (/bundles/:slug)
  3. Checkout complete page (/cart_purchase/:uuid/thankyou) [UPDATE 2018/09/11: A Leanpub author has suggested this worked for him: (/cart_purchases\:uuid/download)]

Just to be clear, ‘slug’ is your book’s or your bundle’s slug, so for the book https://leanpub.com/lean, the slug is ‘lean’.

Events

Events in Google Analytics are broken up into 3 pieces: Category, Action, and Label (optional).

The events we send are as follows, using the category ‘ShoppingCart’, the actions ‘Added’, Removed’, and ‘MovedFromWishList’:

  1. ‘ShoppingCart’, ‘Added’, slug
  2. ‘ShoppingCart’, ‘Removed’, slug
  3. ‘ShoppingCart’, ‘MovedFromWishList’, slug

– Posted by Len Epp

blog comments powered by


Originally published at leanpub.com.

Leanpub

Written by

Leanpub

Leanpub is the best way in the world to write, publish, and sell ebooks. Publish in-progress, serial and complete ebooks in PDF, EPUB and MOBI.