Google Analytics and Chat - Part 3 - LivePerson - What are the 'chatters' doing on my site

In my previous post, I discussed integrating BoldChat and Google Analytics to get deeper insight into what 'chatters' do on your site.
We also have clients that use the LivePerson platform who were interested in seeing their chat data from LivePerson in Google Analytics.
Similar to BoldChat, LivePerson's default Google Analytics implementation causes a number of problems including (but not limited to):
- No cross-domain tracking
- Visitor/visits are bloated
- Referral information is lost
- LivePerson visit information can't be tied back to the visit on the your site
- The LivePerson tracking code sets a UDV - this will not overwrite the _utmv cookie on the clients' site, but these UDV values will show up in your reports
Here are LivePersons PDF instructions for integrating GA
To implement the tracking correctly, you need to disable LivePerson's Google Analytics tracking completely and utilize the customizable chat window feature found in LivePerson. This feature allows you to customize the look and feel of the chat window. For example, we can customize the dimensions, the button images and the background/foreground colors. What we are really interested in is the custom branding. This allows us to control what appears on the right-hand side of the chat window by using iframes. What we want to do is set the source of the iframe to a page that resides on our site. This page will contain both an image (or flash or whatever you like) and the GA tracking code (GATC). When the iframe is loaded, the tracking code will read the visitors cookies from our domain, and then send that visit information to Google. This accomplishes both tracking of the chat window and associating that chat with the visitors current visit on our site.
Setting Up the Page
Create a page with code similar to the following:
<body>
<img src="logo.gif" />
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
try {
var pageTracker = _gat._getTracker("UA-XXXXXXX-X");
pageTracker._trackPageview('/liveperson_chat.html');
} catch(err) {}
</script>
</body>
</html>
Replace the web property ID in the code (UA-XXXXXXX-X) with your own. As well, any customizations to the Google Analytics Tracking Code (GATC) that resides on your site must be made to the above code. For example, if the GATC on your site 'domain.com' uses subdomain tracking, you would modify the code to:
<body>
<img src="logo.gif" />
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
try {
var pageTracker = _gat._getTracker("UA-XXXXXXX-X");
pageTracker._setDomainName('.domain.com');
pageTracker._trackPageview('/liveperson_chat.html');
} catch(err) {}
</script>
</body>
</html>
Also note that I am using a virtual page name for the page view. If you name the file appropriately, you do not need to use the virtual page name.
Updating the Chat Window
To update the chat window, do the following:
- Log into your LivePerson console
- In the menu, navigate to "LivePerson" > "Admin Console". This will open a web browser
- In the new browser window, navigate to "User Experience" > "Chat"
- Ensure "Chat Window" is selected for the "Window Type"
- Click on the "Branding" tab
- Select "Custom" for "Select Image Type"
- Enter the URL for the page you created
- Enter the proper width and height properties
- Click "Save All"
Because LivePerson allows you to customize the different types of windows (prechat survey window, offline survey window, exit survey window, and the chat window) we can track all these types of windows by setting the custom image URL for each window. This way, you can create funnels for the chat process, and/or create advanced segments based off of the different LivePerson windows visitors see.
Analysis
Now for the fun stuff! To segment the data into those who did use chat versus those who didn't, simply create the following advanced segment.
- In "Dimensions", expand "Content" then drag "Page" into the right-side
- Select "contains" for "Condition"
- Enter the URL of the page you created as it would appear in the "Top Content" report. In my example, it would be "/liveperson_chat.html".
Now that you've got the segment, apply it, and compare how these users compare to other visitor segments on your site by looking at things such as Goal Conversion Rate changes between the segments. Do visitors that engage in chat have a higher or lower conversion rate?
This is a great article. I have a question though. If all pages are being tracked in analytics by a pageTracker._trackPageview();
on my master template, doesn't that mean that the conversion rate for my default segment contains live chat conversion as well?
I can see how we are tracking the live chat conversions in the new Live Person Chat segment, but would I not need to do the inverse (create a segment where page does not contain /livechat.html) to get a fair A/B comparison?
You are correct. The default "All Visits" segment that is applied to all reports would report the conversion rate for both visitors who used the chat, and those that did not.
To properly compare visits who used live chat, versus those who (presumably) saw the live chat option but chose not to use it, you would have to create a segment for visits that did not contain the "/liveperson_chat.html" page.
Andre
I you're interested in an A/B comparison, you might consider on doing an A/B test that actually hides the chat button for a segment of your visitors. If you just do a segment of users that open chat versus those that don't, it's a different comparison as you're comparing people that chose to chat versus those that chose not to chat. By hiding the chat button for a segment, you're getting a more realistic view of the value added by chat (or not).
Thanks for the feedback. I know Comodo do a proper A/B test with the trial version of Hacker Guardian. They ask you to add a 1px transparent gif to your receipt page. Then they show you convincing stats comparing conversion rate with the hacker guardian logo, versus conversion rate where it was hidden. It's a good upsell. They handle the reporting in their own account interface.
I basically see how I could serve pages with mysite.com/index?livechat=1 75% of the time and mysite.com/index?livechat=0 25% of the time, and track the relative conversion rates in Analytics.
I am unsure whether hiding the chat window and losing conversions is worth the cost to put a figure on a known outcome. We know chat will increase conversion rate but would it not be expensive for a busy site to put an actual figuer on this?
Mike
That depends on what the value is to you of knowing the answer. If you already know that users with chat convert better, then there's probably no need to run a test that hides the button, but if you're just launching chat on a site, this is a good way to get accurate data on the increased conversions and on busy sites you could set it to run on a small percentage of the traffic if you like.
You could also link the results with your analytics so that you could apply a $ value and do some deeper segmentation on the types of users that are using chat and converting better.