4.1.6 Remarket to Previous Visitors (Dynamic Remarketing)

Value and Business Impact


Dynamic Remarketing lets your advertisers reach people who have previously visited their websites or used their mobile apps, showing them relevant ads when they visit other sites or search on Google. Implementing remarketing tags improves the smart bidding signals for major surfaces (including Display) supported by Performance Max.

UX Guidance


We recommend activating dynamic marketing by default without giving the option to turn it off. You don't need input from the merchant to complete this task, so you don't need to surface this in the UI.

Tech Guidance


To implement dynamic remarketing, you need to place tags on more pages, in addition to the one you placed on the purchase confirmation page:

  • All pages
  • Product page
  • Add to cart button
  • Cart page

You can refer to the general instructions in the dynamic remarketing prerequisites page, but the main takeaway is that the steps for placing these additional tags are similar to the steps for installing the purchase conversion tracking:

  1. Add a global site tag to the <head> of the page, as described in More about the global site tag and where to install it. This global site tag is the same across all pages.

  2. Add an event snippet in the <body> of the page. The content of the event snippet depends on the page type (example snippets below), but they mostly share these components:

The event name you use (for example, page_view) can be a custom event name of your choosing or one of our recommended standard events. It doesn't need to match any specific value for the purpose of implementing dynamic remarketing, as long as the event data parameters (ecomm_pagetype, ecomm_prodid, and ecomm_totalvalue in this example) are correctly set.

Event snippet example for product page

<!-- Event snippet for a product page -->
<script>

  gtag('event', 'page_view', {
    ecomm_pagetype: 'product',
    ecomm_prodid: 34592212, //required, must match Merchant Center product id
    ecomm_totalvalue: 29.99,
    ecomm_category: 'Home & Garden',
    isSaleItem: false
  });

</script>

Event snippet example for add to cart button

<!-- Event snippet for a product page -->
<script>

  gtag('event', 'add_to_cart',{
    send_to: 'AW-CONVERSION_ID',
    value: 29.99, //total value -- important
    items:[{
  id: 34592212, //required, must match Merchant Center product id,
                // item_group_id, or display_ads_id
      price: 29.99, //item value -- important
  google_business_vertical: 'retail', //important
  name: '...', //optional
  brand: '...',//optional
      category: 'Home & Garden', //optional
    }]
  });

</script>

Event snippet example for cart page

<!-- Event snippet for a product page -->
<script>

  gtag('event', 'view_cart',{
    send_to: 'AW-CONVERSION_ID',
    value: 29.99, //total value -- important
    items:[{
  id: 34592212, //required, must match Merchant Center product id,
                // item_group_id, or display_ads_id
      price: 29.99, //item value -- important
  google_business_vertical: 'retail', //important
  name: '...', //optional
  brand: '...',//optional
      category: 'Home & Garden', //optional
    }]
  });

</script>