10 / 10
Sep 2023

This post describes how I track E-junkie conversions resulting from my Google Ads campaigns sending users to my Wordpress site. This was very painful to figure out how to do (and I still may not have it all quite right). I'm posting it here in case others find it useful.


The "new" E-junkie thank you page automatically identifies your Google Analytics account and sends transaction data for the purchase to that account. While Analytics does track E-junkie transactions, it can't attribute most of those transactions (conversions) to the Google Ads campaign ads that brought the users to my web site.

After clicking my ads, most users don't purchase immediately. They often or usually purchase hours or days later after trying the free trial and/or visiting a tutorial Youtube video, and their later visit to purchase is classified by Analytics as a new session. So most of these transactions get a Source / Medium of (direct) / (none), not google / cpc. See this help article for a more detailed explanation:
https://support.google.com/analytics/answer/2679221?hl=en2

Thus, I wanted to use Google Ads conversion tracking, which uses a different attribution model, allowing a conversion that happens days after an ad click to be properly attributed to the ad. Here are the steps I took; these may not be completely right, but they seem to work (I hope I didn't leave anything out):

  1. I installed the free Google Site Kit on my Wordpress site and linked it with my Google Analytics and Tag Manager accounts.

  2. In Google Ads, I created a conversion action:
    https://support.google.com/google-ads/answer/6095821?hl=en&co=ADWORDS.IsAWNCustomer=true8

  3. In Google Tag Manager, I added a Conversion Linker tag and a Google Ads Conversion tag:
    https://support.google.com/tagmanager/answer/6105160?hl=en5
    https://support.google.com/tagmanager/answer/75493906

  4. In Google Analytics, I added e-junkie.com and fatfreecartpro.com to the Referral Exclusion List:
    https://support.google.com/analytics/answer/2795830?hl=en7

  5. In E-junkie, I added the following snippets to the Product Thank-you Page HTML:

<script>
  gtag('config', 'AW-528383436');
  gtag('config', 'AW-528383436', {
      'linker': {'accept_incoming': true}})
  gtag('event', 'conversion', {
      'send_to': 'AW-528383436/1DT7COeLyugBEMz7-fsB',
      'value': [%gross%],
      'currency': 'USD',
      'transaction_id': '[%txn_id%]'});
</script>

The first gtag() provides my Google Ads account id.

The second gtag() sets up the Conversion Linker tag.

The third gtag() is the event snippet for the Google Ads conversion action, from Install The Tag Yourself. The 'value' has been changed from 1.0 to [%gross%], substituting in the total amount of the shopping cart. Similarly for 'transaction_id'.

  • created

    Dec '20
  • last reply

    Sep '23
  • 9

    replies

  • 1.1k

    views

  • 3

    users

  • 2

    likes

  • 5

    links

Yeah perfect! Will have to give this a go.

Tracking across cross domains is challenging.

Trying to work out how to track for Google Ads, Google Optimize and Google Analytics. Also the new GA4 is different too with Google Analytics.

If I work out any of it I will also post.

Just a question - are you selling multiple products and did you paste your code in the thank-you page for the individual product?

Or only 1 product?

I sell multiple products, each with its own Product Thank-you Page. But I'm only running a Google Ads campaign for one of the products, and I pasted the event snippets into its Thank-you Page only.

If you have multiple product sales that could result from your campaign, I think you could paste the event snippet into each of the Thank-you Pages. Alternatively, you could create multiple Google Ads conversion actions, one for each product being advertised, and paste their event snippets into the corresponding Thank-you Pages.

Yeah great - will give it a go. Thanks for posting. Been trying to work out this stuff for months.

I am trying to work out how to track for all these Google products using a Wordpress site and E-junkie FatfreeCart but not E-junkie Marketplace and no E-junkie Wordpress plugin.

So it is a cross domain requirement. In addition using the new GA4 Google Analytics not the old Universal system.

Ideally, to get all the relevant information to track things properly all these products need to be setup in a cross domain environment. Google Ads, Google Optimize, Google Conversions and New GA4 Google Analytics.

So far I have worked out it isn't easy. If I learn anything new I will paste here. If you have any tips feel free to share.

2 years later

Hi John,

Does this method still work?
I want to do the exact same thing you described here (Wordpress + E-junkie) but i'm unsure of how it all works

It worked as of about 5 months ago, when I stopped my campaigns.

Does this refer to the conversion id?

Unfortunately, I don't really remember the details :-<