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:

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:

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?