Easily add Google Ads conversion tracking to Shopify in less than 15 minutes.

Step 1

Log in to your Shopify Admin Panel

Shopify Login Admin

Step 2

Click on Settings (Gear Icon) and choose Checkout

Shopify Checkout

Step 3

Login to Google Ads and click on the 3dot menu in the top right corner and select Conversions under Measurement column.

Google Adwords Menu Conversions

Click on the big blue plus sign and select website as your tracking template.

Then do the following :

  • Conversion name
    • enter any name
  • Category
    • Purchase / Sale
  • Value
    • Use different values for each conversion
  • Attribution model
    • Choose Position-Based
  • The rest can be as default

I have written a great article on how to choose your attribution model.

Click on Create and continue

Create your website conversion action

There are two parts, click on download snippet for the Event snippet

Go back to Shopify and scroll down until you see Order Processing (from step 2), at the bottom of this section you will have a field where you can paste code which is labeled Additional Content and Script.

Shopify Additional Scripts

Copy the send_to value (image below) and replace fa_send_to value with your value.

  • replace AW-123456789/abcdefghijlklmnopq
    • change this value with your event snippet send_to value

Code Example (change the fa_send_to value with your code snippet send_to value)

<!-- FEEDARMY START Global site tag (gtag.js) - Google Ads V1.2 -->
{% assign fa_send_to = 'AW-123456789/abcdefghijlklmnopq' %}
{% assign fa_google_ids = fa_send_to | split: "/"  %}
<script async src="https://www.googletagmanager.com/gtag/js?id={{fa_google_ids[0]}}"></script>
<script>
  window.dataLayer = window.dataLayer || [];
  function gtag(){dataLayer.push(arguments);}
  gtag('js', new Date());
  gtag('config', '{{fa_google_ids[0]}}');
</script>
{% if first_time_accessed %}
<script>
  gtag('event', 'conversion', {
      'send_to': '{{fa_send_to}}',
      'value': {{ checkout.subtotal_price | divided_by: 100.0 }},
      'currency': '{{ currency }}',
      'transaction_id': '{{ order_number }}'
  });
</script>
{% endif %}
<!-- FEEDARMY END Global site tag (gtag.js) - Google Ads V1.2 -->

Testing

You will need to make a test payment to check if the conversion tracking is correctly installed. When you are on the final thank you page of the checkout, use Tag Assistant to validate the code.

Tip:
first_time_accessed is for the page, not for the customer. Subsequent orders will run a first_time_access again for the same person if it is a new browser session.

Need Help?