How to integrate Google Analytics data into email lists

We’re huge fans and advocates of using Google Analytics for your website as part of understanding your digital marketing and email marketing ROI. Most of the time, we use Google Analytics to track what happens after you use email to send customers back to your website. But what if we could use Google Analytics’ tracking codes a little earlier in the process and segment your list with them?

It turns out, this is not only possible, but relatively straightforward. If you have developers or an IT department to help you with some of the coding, please share this post with them.

Google Analytics passes 3 snippets of text along using its URL builder: source, medium, and campaign. When you’re creating trackable URLs for marketing campaigns (via any channel), you assign values to these. For example, if we advertised in the NY Times online edition, we’d specify the source as NY Times, the medium as Advertising, and the campaign would likely be the date the ad ran. Here’s another example, using Facebook ads:

Google Analytics campaign data can be integrated into email lists.

This is an important step to take for any campaign where you want to generate trackable URLs that will show up in Google Analytics, and many of you already do this.

The next step is to add these three custom fields to your mailing list. You can do this in the WhatCounts Publicaster or Professional editions with ease by adding fields to your list, as shown below:

How to create and edit an email list in Publicaster.

The third step, and the part that you may need to have your developers help you with, is to copy Google Analytics’ fields into your subscription forms. Use the programming language of your choice to grab the tracking codes from your website’s URLs and assign them to your mailing list’s fields. Here’s an example using the PHP language:

Publicaster data

Update your subscription forms using this code (it’s invisible to the subscriber). Congratulations! You’re now collecting Google Analytics data in your mailing list. So what can you do with that information? Segment your list and send highly targeted email, of course!

The segmentation manager in Publicaster.

You can and should send separate email campaigns to people who come in via PPC or social media, or track the action rate of different audiences. Any segmentation, tracking, or reporting that you’d do on a piece of custom data, you can do with your newly-tracked Google Analytics data.

I emphasize that this works with both the Publicaster and Professional Editions of the WhatCounts platform; I used Publicaster in this instance since my mailing list runs on it. If you need help implementing this advanced tracking method, please contact our Strategic Services team today. If you’re not a WhatCounts customer, consider contacting us now!

Christopher S. Penn
Director of Inbound Marketing, WhatCounts


Share on LinkedIn39Tweet about this on TwitterShare on Facebook3Share on Google+0

free ebook download

Click Here To Download
2 Responses to "How to integrate Google Analytics data into email lists"
  1. charlesmeaden says:

    This approach is great if people sign up on page they originally landed on, but won’t work if they move to another page. To do this you need to scrape the Google Analytics cookie

  2. Campaign Cog says:

    It’s very useful and important to do this. But if you don’t have an IT department or are not very technical you might struggle with the above! 🙂

    This is one of the reasons why we created an email analytics application that links to Google Analytics via the first method you mentioned automatically. It’s really for those that don’t make use of an ESP like whatcounts.

Leave a Reply

Your email address will not be published. Required fields are marked *