Instant Checkout lets you easily track user purchase events using Google Analytics 4 (GA4). Instant utilises the standard GA4 integration format shown below.
By following this structure, you can ensure that GA4 will receive the event data in the expected format. This is important for accurately tracking user purchase events in GA4.
If your configuration expects data in the recommended format, no further action is required.
If your GA4 configuration expects a different data format, you can find instructions on implementing custom GA4 events by navigating to the custom integration page.
Recommended GA4 Data Structure:
{
transaction_id: "T_12345_1",
value: 25.42,
tax: 4.90,
shipping: 5.99,
currency: "USD",
coupon: "SUMMER_SALE",
items: [
// If someone purchases more than one item,
// you can add those items to the items array
{
item_id: "SKU_12345",
item_name: "Stan and Friends Tee",
affiliation: "Google Merchandise Store",
coupon: "SUMMER_FUN",
discount: 2.22,
index: 0,
item_brand: "Google",
item_category: "Apparel",
item_category2: "Adult",
item_category3: "Shirts",
item_category4: "Crew",
item_category5: "Short sleeve",
item_list_id: "related_products",
item_list_name: "Related Products",
item_variant: "green",
location_id: "ChIJIQBpAG2ahYAR_6128GcTUEo",
price: 9.99,
quantity: 1
}]
}
Viewing Your Data
After about 24 hours, the data you sent with the "purchase" event becomes available in your reports, explorations, and Google Analytics Data API.
The "purchase" event automatically populates a variety of pre-built dimensions and metrics, which are used in your reports, explorations, and so on.
Gtag & datalayer
By default, Instant Checkout will push a 'purchase' event to gtag. However, if your configuration requires the event to be pushed to the datalayer. Please let us know at help@instant.one.
To ensure your Google Tag Manager is set up to track our 'purchase' event, you will need to set up an event trigger. See the documentation about setting up Custom event triggers.