Eliminate Duplicate Transactions in Google Analytics

This simple piece of javascript will reduce (or even eliminate) the number of duplicate transactions which are recorded in your Google Analytics reports.

The script works by checking whether the client browser has already sent a tracking notification to Google for this transaction id. It places a long term cookie on the client machine, ensuring that subsequent views of the same page from that client browser do not send further transaction notifications.

It works by replacing the usual tracking code in your receipt / transaction confirmation web page with the following code:

<script src="checkissent.js" type="text/javascript"></script>
<script type="text/javascript">
if(!checkIsSent('YOUR CART ID HERE')){
 
      PASTE YOUR GOOGLE TRANSACTION TRACKING CODE HERE
  } </script>

Download the script here.

Legalese

Whilst we've made every effort to make this script both bomb and idiot proof, the usual disclaimers apply: Invent Partners accepts no liability for any loss or damages incurred by the use or misuse of this script. Sorry.

“ From the outset, invent Partners got the balance right and were prepared to listen to our needs, whilst at the same time offering their depth of knowledge and experience. The end product we received is exceptional and has since proven its worth, fundamentally from a ‘back end’ input and management information viewpoint and importantly from a ‘front end’ consumer ease of use stance. Needless to say, we are growing our business as a result, with 80% of web business as ‘net new’. ”
Ged, Vertigrow Ltd

Contact Us