Guide · Tracking and data

Google Ads conversion tracking on Shopify: the complete setup

Set up Google Ads conversion tracking on Shopify: create the purchase action, choose a method, add enhanced conversions and fix why Google misses sales.

Updated · 10 min read

By the ROASaurus team

The short answer
  • Create one purchase conversion action in Google Ads that counts every conversion with the order value, and make it the only primary purchase action.
  • On Shopify, the Google & YouTube app sets up the Google tag and a purchase conversion for you; Google Tag Manager or a tracking app are the alternatives.
  • Send the order id as the transaction id and turn on enhanced conversions, so Google can drop duplicates and match orders with hashed customer details.
  • Google Ads misses Shopify sales when the click id is lost, consent is not signalled, or the purchase depends on the browser; uploading orders from the server closes that gap.
  • Smart Bidding optimises on the conversions it sees, so missing or doubled purchases change what Google bids on, not only what it reports.

Google Ads optimises towards the conversions you report. With Target ROAS or Maximise conversion value, the purchases and their values decide which searches, products and audiences get your budget. This guide sets up purchase tracking for a Shopify store from the conversion action to enhanced conversions, compares the ways to send conversions, and explains why Google Ads misses Shopify sales and how to close the gap.

For enhanced conversions in depth, read our post on Google Ads enhanced conversions on Shopify. For a list of symptoms and fixes, see Google Ads conversion tracking problems.

What you need before you start

  • Admin access to the Google Ads account, and to Shopify admin with permission to install apps and edit customer events.
  • A Google Merchant Center account linked to Google Ads if you run Shopping or Performance Max campaigns.
  • A list of every place a Google tag or Google Ads conversion is installed today: the Google & YouTube app, theme code, Shopify's old additional scripts, Google Tag Manager, other apps.
  • A cookie banner that passes consent signals to Google (Consent Mode) if you advertise to the EEA, the UK or Switzerland.
  • A product you can order and refund for testing.

The Google Ads parts and how they fit

PartWhat it does
Google tag (gtag.js)The script that loads on your pages, stores the click id from gclid in the _gcl_aw cookie and sends events to Google Ads and GA4.
Conversion actionThe definition in Google Ads of what counts: a purchase, its value, how many per click, the attribution window.
Conversion id and labelThe AW- number of your account and the label of the action. Together they tell the tag where to send the conversion.
Product feed and Merchant CenterYour products for Shopping and Performance Max. Item ids in conversions and remarketing events must match the feed.
Remarketing eventsProduct views and adds to cart with item ids, for dynamic remarketing. See the dynamic remarketing guide.
GA4 linkLets Google Ads import GA4 audiences and, if you choose, GA4 conversions.

How to create a purchase conversion in Google Ads

  1. Open conversions

    In Google Ads, go to Goals › Conversions › Summary and create a new conversion action for a website.

  2. Choose Purchase

    Pick the Purchase category. Name it clearly, for example "Shopify purchase", so you can tell it apart from imported or app-created actions.

  3. Set the value

    Use different values for each conversion, with your store currency as default. The tag will send the order value.

  4. Count every conversion

    For purchases, each order is a conversion. "One" is meant for leads.

  5. Set the windows

    Choose the click-through window (up to 90 days) and engaged-view and view-through windows that fit your buying cycle. A longer window credits more orders to ads.

  6. Pick the attribution model

    Data-driven is Google's default for most actions. Keep it unless you have a reason to compare.

  7. Install it

    Note the conversion id (the number after AW-) and the label. Then install the tag with one of the methods below.

The ways to send conversions from Shopify

MethodWhat it sendsSetupLimits
Google & YouTube appGoogle tag on the storefront, purchase conversion from checkout, optional enhanced conversions; also the product feedInstall the app, link Google Ads and Merchant CenterFixed set of events and values; you see little of what was sent
Basic custom pixelA conversion event with order id, value and currency from checkoutPaste gtag code into a custom pixel in Settings › Customer eventsRuns in a sandbox; Google does not support it for conversion measurement
Google Tag ManagerWhatever your data layer and tags sendGTM on the theme, plus a custom pixel for checkoutNeeds a data layer; the checkout part runs in the same sandbox
Tracking app with server uploadThe purchase from checkout plus each paid order uploaded from the server with its click idInstall the app, add the conversion id and labelsNeeds API access to the Google Ads account for the server part
Whatever you pick, one purchase action should be primary. Two primary purchase actions count each order twice.

Swipe the table sideways to see every column.

The Google & YouTube app

Google's own Shopify app is the starting point for most stores. Once you link Google Ads and Merchant Center, it installs the Google tag, creates a purchase conversion action and sends purchases from the checkout. You can turn on enhanced conversions in its settings. Google warns that a conversion can be counted twice when the app runs next to another Google tag or a conversion set up earlier, so remove older installations.

A basic manual setup

Without an app, you add the conversion yourself as a Shopify custom pixel. It sends the order id, the value and the currency, and nothing about products or the customer unless you add it. Because Shopify runs custom pixels in a sandbox, the tag cannot read the gclid cookie from your storefront pages, and Google's help says this implementation is not supported for conversion measurement. Use it only as a stopgap.

Purchase conversion in a Shopify custom pixel (after loading gtag.js)
analytics.subscribe('checkout_completed', (event) => {
  const c = event.data.checkout;
  gtag('event', 'conversion', {
    send_to: 'AW-123456789/AbCdEfGhIjk',   // your conversion id and label
    transaction_id: c.order.id,
    value: Number(c.totalPrice.amount),
    currency: c.currencyCode,
  });
});

Enhanced conversions

Enhanced conversions send hashed first-party customer details (email, phone, name and address) with the conversion. Google uses them to match the purchase to a signed-in Google account that clicked the ad, which recovers conversions the cookie alone cannot tie to a click. Turn it on in the conversion settings in Google Ads, accept the customer data terms, and send the details with the purchase, either through the app setting or with gtag('set', 'user_data', …) before the conversion event. Google hashes the values with SHA-256 if you send them unhashed through the tag.

Primary and secondary conversion actions

Google Ads splits conversion actions into primary and secondary. Primary actions count in the Conversions column and Smart Bidding optimises on them. Secondary actions are recorded in All conversions for reporting only. Keep exactly one primary purchase action per store. Typical secondary actions: the GA4 purchase import, add to cart, begin checkout, and a test action you are comparing.

Two primary purchase actions, ROASaurus Demo StoreSample data
Orders from Google Ads clicks in a week120
Purchases recorded by the Google & YouTube app action110
Purchases recorded by an old GTM action, also primary104
Conversions column in Google Ads214
Ad spend€3,000
Reported cost per conversion€14.02
Real cost per order (3,000 ÷ 120)€25.00
Example data for a fictional store. Making the old action secondary brings the Conversions column back to one count per order, and Target ROAS bids on real values again.

How the Google Ads integration works, and why it misses sales

In theory the chain is simple: a shopper clicks an ad, Google adds gclid to the landing page, the Google tag stores it in a first-party cookie, and the purchase tag sends the conversion with that click id. In practice, several links break on a Shopify store:

  • The click id never gets stored. When the Google tag does not load on the landing page (blocked, delayed or missing), gclid is not kept and the purchase cannot be tied to the click.
  • The checkout cannot read it. Checkout pixels run in a sandbox on Shopify's checkout; a tag there only sees the click if it was stored where the sandbox can read it.
  • No consent signal. For traffic from the EEA, Google needs Consent Mode signals; without them it may not use the conversion.
  • Browser-only purchases. Ad blockers, closed tabs and redirects to external payment pages stop the purchase event.
  • Cookie limits. Safari limits how long scripts can keep cookies, so a purchase days after the click may arrive without a click id.

Signs that your tracking is broken

  • Shopify shows clearly more revenue from Google traffic than Google Ads reports, week after week.
  • The conversion action shows "Inactive", "No recent conversions" or "Unverified" in its status.
  • Performance drops when you switch to Target ROAS or Maximise conversion value.
  • Raising the budget raises spend without raising reported conversions.
  • Conversions arrive with values that do not match order totals.

This matters more than a reporting gap. Smart Bidding learns from the conversions it sees. If a fifth of the orders from one campaign go missing, Google lowers bids on searches and products that actually sell.

Why importing GA4 conversions does not fix it

Many stores import the GA4 purchase into Google Ads to fill gaps. It can help visibility, but it relies on the same browser tag, the same cookies and the same consent, so it misses the same orders. GA4 also attributes differently from Google Ads. Import it as a secondary action for comparison, not as a second primary purchase.

Server-side, first-party conversions

The robust fix is to send the purchase from the shop's order data, not only from the browser:

  1. Capture the click id first-party

    Store gclid, gbraid and wbraid on your own domain when the shopper lands, with a first-party visitor id.

  2. Carry it to the order

    Save the visitor id on the cart so it arrives with Shopify's order webhook.

  3. Upload the order

    Send each paid order to a Google Ads conversion action of the "Import from clicks" type, with the click id, the order value, the order id as transaction id and hashed customer details.

  4. Keep one primary

    Make the server action primary and the browser purchase action secondary, or the other way round, so each order counts once.

Google rejects click conversions uploaded more than 90 days after the click, and the transaction id keeps a repeated upload from counting twice. Our server-side tracking guide for Shopify explains the Shopify side of the chain.

Best practices and common mistakes

DoAvoid
One primary purchase action, every conversion countedTwo primary purchase actions (app plus GTM, or tag plus GA4 import)
The order id as transaction idPurchases without an id, which double count on a reload
Order value in the store currency, consistent about tax and shippingA fixed value, or values in a different currency
Enhanced conversions on, with consentCustomer details sent for visitors who declined
Item ids that match your Merchant Center feedProduct ids in one format in the feed and another in the tag
GA4 linked to Google AdsGA4 and Google Ads left unconnected, so audiences and comparisons are missing
A test order after every changeAssuming the app still works after a theme or checkout change

How ROASaurus sends Google Ads conversions

ROASaurus loads the Google tag on the storefront as a conversion linker, so the gclid or gbraid of an ad click is kept in the first-party cookies the checkout tag reads. Its checkout pixel sends the purchase conversion with the order id as transaction id, the items in Merchant Center id format, a new customer flag and, with consent, the customer details for enhanced conversions. Once the Google Ads account connected for ad spend has the Data Manager grant, ROASaurus also creates an "Import from clicks" action, uploads each paid web order to it from the server with the stored click id and hashed customer details, and makes the checkout tag's purchase action secondary so no order counts twice. Google Ads is one of the destinations ROASaurus runs in production today.

In ROASaurusConnections › Tracking & destinations
  1. Install the ROASaurus Shopify app (order webhooks and checkout pixel); the optional custom pixel adds the Google Ads conversion in checkout.
  2. Add the Google Ads destination with the conversion id (the number after AW-) and the purchase conversion label; optionally a begin checkout label and a separate new customer label.
  3. Connect the Google Ads account for ad spend; with the Data Manager grant, the server purchase action is created and filled in for you.
  4. To bid on margin instead of revenue, set a conversion value multiplier (for example 0.4 for a 40% average margin).
  5. Check Data quality › Overview for Google Ads accuracy and Data quality › Deliveries for each upload and Google's answer.
The ROASaurus Mac app showing Tracking health: a card per destination, Purchase accuracy per day for Meta, GA4 and TikTok, and accuracy per payment method. Fictional demo store, simulated data.
The ROASaurus iPhone app showing Tracking health: a card per destination, Purchase accuracy per day for Meta, GA4 and TikTok, and accuracy per payment method. Fictional demo store, simulated data.
Data quality › Overview: accuracy per ad platform, missed orders and match keys. Fictional demo store, simulated data.

With the default consent mode, the order of a visitor who declined is sent to Google Ads flagged as consent denied, without customer details.

Start freeOpen the live demo14-day trial of every feature, no credit card.

Sources

  1. Google Ads Help: Set up conversion tracking for your website
  2. Google Ads Help: Set up conversion tracking with the Google & YouTube app on Shopify
  3. Google Ads Help: About enhanced conversions
  4. Google Ads Help: About primary and secondary conversion actions
  5. Google Tag Manager Help: Limitations of using a custom pixel for conversion measurement on Shopify
  6. Google Ads Help: About offline conversion imports
  7. Google for Developers: Send offline conversion events with the Data Manager API
  8. Google for Developers: Consent mode

More guides on tracking and data · All guides

FAQ

Questions, answered

More answers in the FAQ and the help center.

How do I set up Google Ads conversion tracking on Shopify?

Create a purchase conversion action in Google Ads, then install it with the Google & YouTube app, Google Tag Manager or a tracking app. Send the order id and value, turn on enhanced conversions and keep one primary purchase action.

How do I track conversion value in Google Ads for a Shopify store?

Set the conversion action to use different values per conversion and send the order value and currency with each purchase. Decide whether the value includes tax and shipping and keep it the same everywhere.

Can I use Google Tag Manager for conversion tracking on Shopify?

Yes, on the storefront through the theme, and in checkout through a custom pixel. In checkout, GTM runs inside Shopify's pixel sandbox, which Google does not support for conversion measurement, and its preview mode does not work there.

Is there a Shopify app for Google Ads conversion tracking?

Google's Google & YouTube app sets up the Google tag, a purchase conversion and the product feed. Tracking apps add server-side uploads and more control over values and events.

Should my Google Ads purchase be primary or secondary?

Make one purchase action primary, so Smart Bidding optimises on it. Set every other purchase action, including a GA4 import, as secondary.

Why does Google Ads show fewer conversions than Shopify?

Google only counts orders it can tie to an ad interaction within the window. Beyond that, lost click ids, missing consent signals and blocked browser tags cause real loss. Enhanced conversions and server uploads recover part of it.

Why are my Google Ads conversions doubled?

Usually two primary purchase actions, or the same action installed twice (the Google & YouTube app plus older code). Check the actions in Goals › Conversions and remove or demote the extra one.

Do I need enhanced conversions?

It is optional but recommended by Google for purchases. It sends hashed customer details so Google can match more orders to ad clicks. Send them only where you have the shopper's consent where consent is required.

Every sale, traced to the ad that earned it

Server-side tracking, profit and lifetime value in one app. Free plan, no credit card.