One of the most frequently visited reports in Analytics is the Source / Medium report. This is a primary reason why it’s targeted by referrer spammers, as we discussed in a recent article. There is, however, a much more trivial, yet common issue with the source / medium report that we see during audits and setups.
It’s the issue of proper attribution of conversions/ecommerce transactions towards a traffic source in the presence of payment gateway referral traffic. In many cases the implementation of a payment gateway requires that some traffic is sent to the payment gateway site and back to your site. This results in a visit with source “your payment gateway domain” and medium “referral” to be recorded in Google Analytics.
In the example above we see a very common scenario: PayPal.com being recorded as the source for all or some of the transactions.
Why does it happen?
Google Analytics starts a new session whenever a user comes to the site from a traffic source different than the previous one (and when it’s not a direct visit), even if the previous session hasn’t expired. The user browses your site and decides to purchase. You send them to the payment gateway one way or another and then he’s sent back after a successful transaction. When the user arrives at the site from the gateway the HTTP headers contain referrer information saying that the visitor is coming from your payment gateway hostname, in the example above: PayPal.com. Many of the other popular payment gateways like Shopify, Authorize, WorldPay, Gate2Shop, etc. also employ a similar solution which results in referrer traffic from them getting credit for your ecommerce transactions.
What’s the harm?
The harm is rather obvious: it prevents you from seeing the original traffic source that was responsible for bringing the transaction. Instead of seeing you got 50 transactions from Google / Organic and 100 more from Google / CPC you now see 150 transactions coming from YourPaymentGateway.com / Referral.
Sure, you can extract the data with some work using the MCF reports or the Attribution Modeling tool, but why? The payment gateway as referrer tells you nothing you didn’t know and is in this sense a data pollution that should be avoided.
How to determine if you are affected?
You should check for sessions, coming from your payment gateway’s domain name (or in some cases names). You can do that by navigating to the Acquisition > All Traffic > Source/Medium report in Google Analytics.
If you are using our Google Analytics Health Checker tool you now have an in-built function that automatically performs this for you. When you run the health report, you’ll get a FAIL and a short description of the issue if we detect such traffic from a list of over 20 popular payment gateways. A table showing the traffic source/medium that the tool identified as wrongly attributed payment gateway traffic is shown as well, containing data about the number of sessions, number of transactions and the transactions per session for each source.
How to exclude payment gateway referrers?
There are two methods to accomplish this.
First method: the Referral Exclusion List
If you are using Universal Analytics, the recommended way to do this is to use the Referral Exclusions feature. It’s accessible via the Google Analytics interface under Admin > (Property) Tracking Info > Referral Exclusion List. You need to add the hostname – either the domain name or a specific subdomain only, to the list. This assures that a visit with a referrer field set to a URL under that hostname will not start a new session if there is already an active session.
Here is what our Referral Exclusion List looks like:
The important line here is secure.gate2shop.com, since this is our shopping gateway hostname. This way we don’t see visits from our gateway when you sign up for a paid plan with us.
Second method – utm_nooverride=1
This was the only method before Universal Analytics. However, prior to UA there was also much less need for it, since for a very long time Google Analytics wouldn’t start a new session for the same visitor if an old one has not yet expired. Then, when they made the change the need to use utm_novverride=1 suddenly jumped and that’s why they added the Referral Exclusion List as a feature.
utm_nooverride=1 is a parameter that you attach to your payment gateway return pages. Say your return page is /checkout/payment/success. You need to provide this URL to your payment gateway: /checkout/payment/success?utm_nooverride=1 . This way Google will ignore the referrer information for this session if there is already another session in progress. This is not what this parameter was originally intented for, but it does the job nicely as I can confirm through my deployment of such solutions.
Remember, you need to do this for all links from the payment gateway to your site and this is not a recommended solution if you are on Universal Analytics.Payment Gateway Referral Exclusions in Google Analytics by Georgi Georgiev