SEO Blog:

SEO Tips- Capturing Google campaign data in form submissions, from cookies

27th July 2010

Back in May 2009 Google made it absolutely clear (via Myth 7) that you can use your analytics data and add it to other systems, such as CRMs. We’ve been working for a while on a few implementations of this, and its turning out well. The exception is that we don’t squirt the captured data into any other systems, rather we create the means for website owners to do this- by reporting well specified and ordered data.

It might not be brand spanking new but with many things related to SEO, analytics tips tend to hold their value.

The deal is that when you are running analytics on a site, and that site has a form, you can use the Google cookie and extract information from it to report information outside of the analytics dashboard.
You can also use the cookie data for other more specific campaigns where you are using utm campaign tags.

Anyway, getting back the form. When someone fills out a form you get a notification via email, and may also be able to see the sent data in some sort of website admin control panel. The data you get back will be whichever fields in the form have been filled in. Here is a form:

Sample Form

…and here is the captured data, from the notification email:

Name: Mrs Contact
Company: The Number Contact Store
Telephone: 01234 567890
Email Address: m.contact@contactnumber.com
Website: www.contactnumber.com
How can we help?: I liked filling in your contact form, it was great.

What this doesn’t tell you is how they arrived at the site, the search engine, paid or organic, the keyword used, maybe even the content of the ad (if it was a paid visit), and the name of any utm tagged campaign that it is associated with.

Yes, you can get much of that data from the analytics dashboard, but it is dead handy to have it reported so that each form submission has its own unique data trail. It can be shared around the organisation easily, and it can be pumped into other systems such as CRMs- so that for example, Mrs. Contacts record in your CRM can show that she came from a paid search campaign using the keyword “bananas for filling in forms”. You can also compile such data for bottom-line reporting to say for example that of all the marketing campaigns you ran last quarter the best returns came from X, Y and Z.

To get that data recorded, and reported, you could develop your own API applications- if you have the skills. But by using JavaScript or other languages (see this book for a PHP option) you can still have it, with relatively little effort. There is a great resource here, and the updated version here, both written by Justin Cutroni.

The script/code needs be added to the page that contains the form, and it can be configured to cover a wide range of options, depending on how you’ve set up the utm campaign tags. An example of the type of information you could get is:

Source = Bing
Medium = Microsoft adCenter
Keyword = Get Mo Leads
Campaign = Mo Leads week 49

…and remember that this will be associated with each unique form completion- very handy data I’ll think you’ll agree.

The next challenge is to see how all this is affected by the new(ish) asynchronous tracking code from Google. Theoretically it should be OK, as the ga.js is unaltered, but we’ll get back to you if anything odd pops up.

These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Facebook
  • LinkedIn
  • Digg
  • del.icio.us
  • StumbleUpon
  • Google Bookmarks
  • Slashdot
  • Squidoo
  • Technorati
  • Reddit
  • Sphinn
  • NewsVine

Other posts you might like...

Leave a Reply