Webflow sync, pageviews & more.
NEW

What are the required fields and completion URL in Webflow for enabling Google Analytics e-commerce sales tracking with Tag Manager?

TL;DR
  • Ensure Webflow's order confirmation page (default path: /checkout/confirmation) includes GA purchase data in window.dataLayer, including transaction details and product items.
  • In Google Tag Manager, create a trigger using either the confirmation page path or a custom 'purchase' event to fire the GA4 Purchase tag.

To enable Google Analytics e-commerce sales tracking via Google Tag Manager in Webflow, you need specific data fields on the checkout and order confirmation pages, and a proper completion URL to fire the purchase tracking tag.

1. Required Fields for GA E-commerce Tracking

Google Tag Manager needs access to the transaction details populated in the Webflow Order Confirmation Page. Webflow automatically injects this data into a JavaScript object called window.dataLayer, but you should confirm the following fields are included:

  • transaction_id (Webflow Order ID)
  • affiliation (e.g., "Webflow") — optional
  • value (Total transaction amount)
  • currency (e.g., “USD”)
  • tax (Sales tax amount)
  • shipping (Shipping cost)
  • items[] (An array of purchased products, each with):
  • item_id (Product ID or SKU)
  • item_name (Product name)
  • price (Unit price)
  • quantity (Quantity purchased)

Webflow includes these automatically on the Order Confirmation Page when using Webflow’s e-commerce.

To verify, preview a test purchase and open the browser console. Type window.dataLayer and look for a "purchase" event containing those fields.

2. Completion URL for GTM Trigger

Google Tag Manager needs a trigger to know when a purchase is complete. In Webflow, this is usually identified by the order confirmation page, which lives at the default path:

  • /checkout/confirmation (This may be different if you renamed default checkout paths.)

Use this path to configure your GTM trigger:

  • Trigger Type: Page View
  • Condition: Page Path equals /checkout/confirmation

Or, more securely:

  • Trigger Type: Custom Event
  • Event Name: purchase (if pushed via dataLayer using a custom event)

Make sure your GTM tag for “Google Analytics 4 – Purchase” listens for this trigger.

3. Notes on Setup

  • If you're using Google Analytics 4 (GA4), use Enhanced E-commerce format, and trigger the "purchase" event with event: 'purchase' in the dataLayer.
  • If you're using Universal Analytics, know that GA3 support officially ended July 2023.
  • You do not need to manually add any fields in Webflow—just ensure your project uses Webflow E-commerce, and the order confirmation page is live and connected.

Summary

To track e-commerce purchases in GA via GTM on Webflow:

  • Ensure your order confirmation page (default /checkout/confirmation) has the necessary dataLayer fields, especially for purchase events.
  • Use window.dataLayer to verify these fields post-checkout.
  • In GTM, trigger your purchase tag using either the URL path or custom event ‘purchase’ on that page.

This setup allows you to accurately report e-commerce transactions from Webflow into Google Analytics via GTM.

Rate this answer

Other Webflow Questions