Add to Google Add to Bloglines Add to Newsgator Add to Yahoo! Contact ROI Revolution Sign Up for the ROI Newsletter Unofficial Google Analytics Blog Feed Unofficial Google Analytics Blog
Unofficial Google Analytics Blog by ROI Revolution

Categories Search This Blog Blogroll Archive

| |

May 2, 2007

Matching Specific Transactions to Specific Keywords

By Shawn Purtell, Google Analytics Support Tech

moneyroll.jpgOne of the great things about Google Analytics is the ability to view overall trends for your website. You can, for example, see how well all visitors who come from AdWords are reaching one of your goals. You can see how valuable the average visit from an email campaign is to your ecommerce business. You can see total transactions and revenue, and see what percentage of transactions are coming from a specific marketing source.

But what if you want to see where a specific transaction came from? What if you get a very large order and you want to see what the marketing source for that specific order is? Well, now you can, with a set of three custom filters that work together.

Here are the details:

The first filter in the set, which I'll call Trans List Mod 1, grabs the campaign source and medium of a visit, and sticks in a custom field.

Click here for Filter #1

The second filter adds the keyword (bid term only) to the custom field. For those of you keeping score, the custom field now contains the source, medium, and keyword.

Click here for Filter #2

The final filter takes that custom field we created and appends it to the transaction order id. This matches up sources with specific transactions.

Click here for Filter #3

After you've created these filters, your filter list should look like this:

transfilterlistsmall.jpg
Click on the image for a larger view

Make sure the three filters appear in the order shown above.

The cumulative result of these filters will look something like this:

transaction%20list%20small.jpg
Click on the image for a larger view

As you can see, the traffic source responsible for the transaction will now show up in the transaction list. Easy as pie!

A warning for the wise: I strongly advise you to create a new profile when using this filter set. Keep your other profiles neat and clean, and if you make a mistake with one of the filters, nothing will be hurt. Remember, once you mess up data in Google Analytics, there's no way to get it back!

For those of you that decide to employ these filters, I'd love to hear your feedback. Feel free to post a comment, as we always love to hear what you have to say!

Find The Secret To Solid, Sustainable Improvements To Your Website
Learn the insider secrets to making more money from your website than ever before – Guaranteed! Get started right away with the Google Analytics Training Course.

Posted by Shawn Purtell at 4:01 PM









Filed under: , , ,

TrackBack

TrackBack URL for this entry:
/mt/mt-tb.cgi/223.

Comments

Hi Shawn,

We've also done some work with this and also had a lot of head scratching to get the results - great post though and cleared up a couple of areas. Regards

Chris

Posted by: Chris at May 3, 2007 4:56 AM

@Chris:

Thanks for the nice comment. Let me know if these new filters work out for you. I've only been using them for a little while, so it would be great to get some feedback.

Posted by: Shawn Purtell at May 3, 2007 8:42 AM

Hi Shawn,

Great post mate. Like Chris, I've been scratching my head over this & have a couple of clients that will absolutely love this. Thanks :)

Mikey

Posted by: Mikey at May 3, 2007 8:22 PM

@Mikey:

Thanks! I hope it turns out to be as useful as I think it might. I'd love to hear feedback from you once you've used the filters with clients.

Posted by: Shawn Purtell at May 4, 2007 9:05 AM

Great Post. These advanced filters are very usefull. I took your training course on Google Analytics. I was wondering if in the future you are going to offer a whole course on advanced implementation and setup where filters like these are taught and where regular expressions could be learned?

Posted by: Krista at May 17, 2007 10:31 AM

@Krista:

Thanks for the compliment. The training course that you took includes the most common advanced implementation options that we've encountered (things like Paypal, cross-domain tracking, etc.). We've also included the general ideas about the types of filters you can create. We're currently revamping the course for our new training series, and it will include more about filters and how you can use them to accomplish specific tasks.

In order to get more specific than that, you really need one-on-one attention, because setting up advanced filters really depends on your site and what kinds of information you want to find. This is one example of something our support plans can do for you on an individual level. We try our best to make this information freely available through our blog.

The same sort of thing applies to regular expressions. Regular expressions can get extremely complex, so we covered the most basic/common ones that you can use in our training course. Again, the more advanced regular expressions are only needed in very specific situations that would require one on one attention.

This brings up another point: Google Analytics is like getting a suit (or dress) fitted - you need to take measurements and personal tastes into consideration when you are setting up analytics. There are some steps that are universally important, but when you start looking at your individual site, no two Google Analytics configurations will be exactly alike.

I hope you found this useful. Thanks again for posting and for taking our course!

Posted by: Shawn Purtell at May 17, 2007 11:13 AM

Hi, Shawn.

I really enjoy reading your blog. Thanks for the information. I was wondering, in the first filter you name the constructor field 'custom field 1' and you call it the same thing in the next filter. But (I think)the second filter refers to the custom filed in the first filter. If they are both named the same thing, does the field from the 1st filter overwrite the field from the second filter? And is there any reason why you wouldn't name them differently? Would there be any benefit in naming them customer field 1 and customer field 2?

Thanks! Shareen

Posted by: Shareen Jordan at June 5, 2007 3:04 PM

@Shareen:

Thanks for the compliments. As far as your question, I only had to use a single custom field across all three filters.

So, filter 1 puts the source and medium into custom field 1.

The second filter reads the custom field from filter 1 and adds the term to what was already there.

The final filter adds the custom field we built in the previous two filters to the transaction id.

This is why the order of these filters is so important. They will not work out of sequence (they also should be next to each other on the filter list).

I didn't use two separate custom fields (although I could have) because I really only needed one.

As far as 'naming' the filter fields, you can't do that. You are given two custom fields you can use. I didn't actually name those, I selected them from the pulldown. Thanks for reading!

Posted by: Shawn Purtell at June 5, 2007 3:10 PM

Great post Shawn - this is gold.

I have a question related to this subject. What I really want to do is to take this info (source and keyword) and pass it into a contact form so that we can implement closed-loop tracking of enquiries.

Do you have any ideas on how that might be done?

Bests,
Will

Posted by: Will at June 14, 2007 4:05 AM

@Will:

It can be done. There are actually two methods I know of to do this. Unfortunately, this kind of thing is too advanced for a blog comment, but feel free to contact us if you want help setting this up.

Posted by: Shawn Purtell at June 14, 2007 9:07 AM

Can this be done for organic traffic ? i.e. finding the keywords that deliver conversions from non-paid natural / SEO sources ? Cheers - Al

Posted by: Al at July 30, 2007 11:31 AM

@Al:

These filters will include organic keywords as well. You can check out the screenshot above for some examples of this.

Thanks for reading!

Posted by: Shawn Purtell at July 30, 2007 11:50 AM

Shawn-

Excellent work. I've just started using GA and was annoyed that there was no built-in functionality for that sort of origin tracking in ecommerce transactions - glad to see it can be added fairly easily!

Posted by: Brian Hinkle at July 30, 2007 2:38 PM

@Brian:

That's the whole idea - making this awesome free tool (GA) more and more useful.

Thanks for the comment!

Posted by: Shawn Purtell at July 30, 2007 2:50 PM

I use it and get some interesting (great) results. Some transactions are direct which I assume are bookmarked traffic

#312676 (direct) - (none) ()

and other transactions are like the one below do not have a value for the keyword I suppose since it is another site sending the traffic.

#312632 some-referring-site.com - referral ()

Everything else looks killer!

Thanks.

Posted by: Fonts at July 31, 2007 1:48 PM

@Fonts:

Thanks for the feedback! Direct sources can mean a couple different things. Usually it means a user typed your URL into the browser directly, but there are some other things that will cause this, like email visits from a program like Outlook.

And you are correct with your second point - referring sites obviously will not have any keyword data, and so the parentheses will be blank.

Thanks again for the feedback!

Posted by: Shawn Purtell at August 2, 2007 3:58 PM

This is a great use of filters to achieve an extremely useful result. However, I think combining it with your excellent Exact Keyword Matching script really takes it to the next level.
I added another filter to append the User Defined Value (the exact keyword) after the Campaign Term. Now my transaction data shows the exact search string that led to the conversion. Very cool.
Question: is there a place to learn the syntax used in these custom filters (e.g. $A1 ($B1))? It seems pretty straightforward but I can't find any information about it in the GA Help documentation.
Anyway, thank you all for your excellent tools, they really take Google Analytics from good to great.

Posted by: Nathan Scheffey at August 2, 2007 5:55 PM

@Nathan:

I agree. If you have Michael's exact keyword tracking script installed, this is a great addition, and we actually do that ourselves.

To be honest, I don't have a specific resource for you concerning regular expression string matching variables, but there are lots of great books and websites on the subject.

Posted by: Shawn Purtell at August 3, 2007 8:53 AM

Hi Shawn.

I've tried doing this on 2 different analytics accounts, and can't get it to work.

I've copied everything word for word, but the keywords are never added. Could it be because the screenshots are of the previous version of analytics?

Posted by: Neil at August 17, 2007 11:13 AM

@Neil:

These filters have been tested and confirmed in the new version of Google Analytics.

I can't say for sure where your problem is occurring, but I can tell you that these filters work fine if used properly.

Is it possible you are having problems with your referring source tracking? Also, remember that keywords only show up for organic and cpc results - not for anything else (referrals, direct, banners, and other sources do not have keywords associated with them).

Posted by: Shawn Purtell at August 20, 2007 8:51 AM

Great stuff Shawn, very usefull.

Just having 1 problem, the first filter that grabs the source and medium, in the output filed you have $A1 - $B1

Thats exatly how I entered it but in my Transaction I am not getting the "source" I do get the keywords

So I get something like this:
Order27 $A (keyword)

Posted by: Prince at August 21, 2007 12:01 AM

It works! Sort off...

Thanks for your help Shawn. I've just logged into Analytics, and it seems that the filters need to be in place for 24 hours to return anything.

Only wish I should filter on Adwords Campaigns instead of Campaigns (no option that I can see).

Posted by: Neil at August 21, 2007 7:19 AM

@Prince:

Looks like there's a problem with one of your filters - the third one I believe (specifically the $A1 part). Make sure there is no space between the $A and the 1. I can tell there is something wrong with your output field because '$A' is showing up in your data, and it should never do that.

Posted by: Shawn Purtell at August 21, 2007 9:15 AM

@Neil:

Glad you got things working. And yeah, Google Analytics data generally takes 24 hours to update completely, so anytime you make a change, you need to give it time.

As to your other wish, I'm not really sure what you're asking. There are filters that can do all kinds of things. If you can be more specific, I may be able to help.

Posted by: Shawn Purtell at August 21, 2007 9:17 AM

I'm accessing Analytics through my Adwords account. This means all my campaigns are listed under Adword campaigns, which isn't shown in the filters dropdown.

What I'm trying to do is, display the keyword(s) that the user types in to make their transaction eg:

Transaction ID, Source, Medium, (Keyword)

Is this possible?

Posted by: Neil Munn at August 22, 2007 5:59 AM

@Neil:

The filter set I provided does this automatically, if the keyword exists. You can see in the image above that the keyword should be present for all organic and cpc (including AdWords) sources.

You should not need any additional filters to achieve this result. If you aren't seeing this data, you may not have the filters set up properly.

*Note - There is a difference between 'what the user types in' and the keyword you are bidding on.

The 'term the user typed in' is called the search term while the keyword you bid on is called the bid term. The bid term is the information you will see.

To find out how to get search term info as well, visit Michael's awesome solution here.

Posted by: Shawn Purtell at August 22, 2007 9:33 AM

Hello - I've been using this filter pretty much since you posted it, and it worked just fine. But I created a new profile for it, and it hasn't worked since. Could it be the new Google Analytics code? I then tried to put it back on the original profile on which I had it, and it *still* doesn't work. I haven't changed any of the code, I have the three filters in the proper order - the only thing that has changed was the Google analytics code. And actually, I'm testing that on still another profile, so I'm not entirely sure what's going on now.

Posted by: Netmeg at January 22, 2008 11:08 AM

As an update to my previous post, I went and checked, and between and my partners, five ecommerce sites that were using this filter ALL stopped displaying the data on January 15th. How weird is that? Google must have changed something.

Posted by: Netmeg at January 22, 2008 1:34 PM

@Netmeg:

There have actually been reports of all advanced filters breaking around that same date, but many people have also stated that their filters have begun to work again. I'd check the more recent data again. In the meantime, we're conducting our own investigation concerning why advanced filters have had this little hiccup, and we'll let you know if we find anything important.

Posted by: Shawn Purtell, Google Analytics Support Tech Author Profile Page at January 23, 2008 8:59 AM

As of today, 1/23/2008, none of our advanced filters are working.

Thanks in advance for anything you find out.

Posted by: Netmeg at January 23, 2008 10:51 AM

@Netmeg:

After examining some other data and situations with both custom and advanced filters, it seems this is an issue many people are experiencing. From the Google Analytics help group to our own data, we have noticed two things:

Many custom filters seemed to stop functioning for several accounts for a brief period around Jan8th, but resumed working on the 15th. This includes custom includes and other custom filters.

Advanced filters that use custom fields, however, seems to be having more trouble, and in many cases have not worked since the 15th on January. Among these kinds of filters is the filter described in this article.

As soon as we get a good explanation as to what's been causing these errors, I'll be sure to post an update here.

Posted by: Shawn Purtell, Google Analytics Support Tech Author Profile Page at January 29, 2008 10:42 AM

Is anyone using this advanced filters getting data? Is it working correctly?

I have had this installed for over a week and have seen no changes to my transaction list under Eccommerce -> Transactions.

Steve

Posted by: Steve Racicot at February 18, 2008 11:14 AM

@Steve

Any advanced filters that use custom fields have not been working since January 15th, including this one. This should be a temporary issues, but in the meantime, we have posted an article on an alternate set of filters you can use that function exactly the same as this set. You can get your filters there, and then refer to Shawn's article here for addition instruction and information.

Posted by: Jeremy Aube at February 18, 2008 3:55 PM

Really informative post.
One question: Where can I find the Transaction List, the last image. I am using the old version of analytics code.

Thanks in advance

Posted by: Imran Khan at February 20, 2008 6:39 AM

@Imran:

The Transaction list is under the Ecommerce section in Google Analytics, and will only show up if you have turned on Ecommerce in your profile settings. The exact report you're looking for is called Transactions.

As a note here, I realize these filters have not been working correctly since Jan. 15th. The filters are still correct, but there was a bug with custom fields (which these filters use) that is being resolved. Until then, feel free to look at Jeremy's update, which gets around this temporary issue.

Posted by: Shawn Purtell, Google Analytics Support Tech Author Profile Page at February 20, 2008 8:57 AM

Have these filters every returned to working properly? I added them before reading to the bottom of the comments. I'm finding that when I view transactions I get the transaction number followed by the state.

Posted by: Asher at June 9, 2008 10:49 AM

@Asher:

These filters have been working correctly for a while now. These three filters do not affect the state of a user, so I wonder why you are seeing that information within Google Analytics. My hunch is that either there is a problem with the way you've set up the filters in your profile, or you have another filter that's using the Custom Field that's interfering with the transaction filters. Unfortunately, it's hard to tell you exactly what the problem is without seeing your filter setup.

Posted by: Shawn Purtell, Google Analytics Support Tech Author Profile Page at June 9, 2008 1:15 PM

Post Your Comments

Post a comment

Contacting ROI Revolution

Telephone Number:
(919) 954.5955 ext. 306
ask for Meredith Smith

Office Fax:
(919) 954.4767

Address:
3109 Poplarwood Ct.
Suite 219
Raleigh, NC 27604


Authorized Google Analytics Consultant

Google Analytics Certified Service and Support Consultant


Free Webinar!

Join a Live FREE Google Analytics Training Webinar
Register now to learn how to
turn Google Analytics into
pure profit! You'll learn how to use many of the key reports, a ten-step system for properly configuring Google Analytics on your website, and how to apply what you learn to the attainment of your online goals. Register for our free Google Analytics training webinar today.


Subscribe to the
ROI Revolution Google
Analytics Newsletter today

Free monthly email publication that contains valuable, practical tips, secrets, and much more! Subscribe to our free Google Analytics newsletter today.


Looking to Purchase
Urchin 5 Software or Fee
Based Support?

We are a Urchin software certified service and support partner! Buy Urchin 5 software, profile packs, load balancing modules, campaign tracking, or fee-based support today.