--- title: "Product-level tracking" slug: "product-level-tracking-2" updated: 2026-10-14T11:12:12Z published: 2026-10-14T11:12:12Z canonical: "help.awin.com/product-level-tracking-2" --- > ## Documentation Index > Fetch the complete documentation index at: https://help.awin.com/llms.txt > Use this file to discover all available pages before exploring further. # Product-level tracking Product-level tracking enables an advertiser to produce much more in-depth reporting where the performance of individual products can easily be measured. From an implementation perspective, as long as you are already utilizing the [MasterTag](/developers/docs/advertiser-mastertag), it’s as simple as adding a hidden HTML form element to the confirmation page that contains individual rows in a specific format outlining which products are included in the order. > [!NOTE] > Note > > - The declaration of product-level tracking must be done before the [MasterTag](/developers/docs/advertiser-mastertag) loads. > - The basket parameter values must not contain pipes, as those are used as delimiter. ## Templates ### Template part 1 - Start of PLT declaration ```xml
``` ## Examples ### Example 1 - HTML form elements ```xml ``` ### Example 2 - JavaScript append ```javascript // 1. Example Data (e.g., from a shopping cart object) const aw_advertiserId = '1001'; // replace with your Awin advertiser programme ID const aw_orderReference = 'AA000006'; // replace with your onlineshop unique purchase orderid const aw_basket = [ { id: 'B000EMSUQA', name: 'The Knife – Silent Shout', price: '5.55', qty: 2, sku: 'B000EMSUQA', group: 'CD', cat: 'Electronic Music' }, { id: 'B001N2Z41Y', name: 'Sigur Ros - Heima', price: '14.99', qty: 1, sku: 'B001N2Z41Y', group: 'DVD', cat: 'Music DVD' } ]; // 2. Creation of the sProductData string let aw_sProductData = ''; aw_basket.forEach(item => { // [Deduction]: Since pipes serve as delimiters, they must be removed from the values or encoded. // In addition, according to the documentation, values must be URL-encoded. const aw_basket_row = [ 'AW:P', aw_advertiserId, encodeURIComponent(aw_orderReference), encodeURIComponent(item.id), encodeURIComponent(item.name), item.price, item.qty, encodeURIComponent(item.sku), item.group, encodeURIComponent(item.cat) ].join('|'); // Each line must end with \r\n. aw_sProductData += aw_basket_row + '\r\n'; }); const awProductsForm = document.createElement("form"); awProductsForm.name = "aw_basket_form"; awProductsForm.setAttribute("style", "display: none;"); document.getElementsByTagName("body")[0].appendChild(awProductsForm); const awProductsTextArea = document.createElement("textarea"); awProductsTextArea.id = "aw_basket"; awProductsTextArea.wrap = "physical"; /*** sProductData in this example contains the correctly formatted product lines ***/ awProductsTextArea.value = aw_sProductData; /*** Each line must be terminated by a line break, more specifically "\r\n" ***/ document.aw_basket_form.appendChild(awProductsTextArea); ``` ### Example requests If product-level tracking, as well as the [conversion tag](/developers/docs/conversion-tag) and the [MasterTag](/developers/docs/advertiser-mastertag), all have been implemented correctly then tracking requests similar to the below will be made. ```plaintext https://www.awin1.com/basket.php?product_line=AW%3AP%7C1001%7CAA000006%7CB000EMSUQA%7CThe%20Knife%20-%20Silent%20Shout%7C5.55%7C2%7CB000EMSUQA%7CCD%7CElectronic%20Music https://www.awin1.com/basket.php?product_line=AW%3AP%7C1001%7CAA000006%7CB001N2Z41Y%7CSigur%20Ros%20-%20Heima%7C14.99%7C1%7CB001N2Z41Y%7CDVD%7CMusic%20DVD ``` > [!NOTE] > Note > > Depending on your advertiser program’s set up, you could see tracking requests being directed towards our alternative tracking domain `zenaps.com`. ## PLT for conversion pixel and S2S > [!WARNING] > Important > > The Image pixel will break on character lengths longer than ~7500 so this version must no be used for extra-huge basket sizes with long product names. In general ~ 40-60 products should be fine, depending on article name and description length. You should save characters by URL-encoding just the array values, but not the array separator pipe. Pixels with a http header size bigger 8 kb will be rejected. As an alternative, for conversion pixels ([S2S](/developers/docs/direct-s2s) and fallback, refer to the topic [fallback conversion pixel](/developers/docs/fall-back-conversion-pixel)), it’s possible to declare product-level tracking within the pixel’s URL request string. Do this by populating each ‘product row’ of above HTML basket form as an entry to the array `bd`. Each product needs to be transmitted as one single GET query parameter. The parameter names are `&bd[0]=&bd[1]=&bd[2]=&bd[3]=...` . The array - which will be the parameter value - must be URL encoded. The separator pipes inside the single parameter value may be encoded, but also can be left unencoded to avoid reaching the character limit. Examples - &bd[0]=AW:P|advertiserId|orderref_encoded|productid_encoded... - &bd[0]=AW%3AP%7CadvertiserId_encoded%7Corderref_encoded%7Cproductid_encoded... ### Template - Fallback conversion pixel and S2S ```plaintext &bd[0]=AW:P|{{advertiserId}}|{{orderReference}}|{{productId}}|{{productName}}|{{productItemPrice}}|{{productQuantity}}|{{productSku}}|{{commissionGroupCode}}|{{productCategory}}&p1={{customParameter1}}&p2={{customParameter2}} ``` - Non-numerical values must be URL-encoded, or the whole array (~query parameter value) must be URL encoded. - `&bd[0]=` is an array and should be sequential for extra products. e.g. *&bd[0]*, *&bd[1]*, *&bd[2].* - `{{advertiserId}}` must be replaced by the applicable Awin advertiser program ID. Consult your account contact or assigned integrator if in any doubt. - `{{orderReference}}` must be replaced by the unique booking / order reference. The parameter value has to be URL-encoded. - `{{productId}}` must be replaced by the applicable product ID (which must be unique). The parameter value has to be URL-encoded. - `{{productName}}` must be replaced by the applicable product name. The parameter value has to be URL-encoded. - `{{productItemPrice}}` must be replaced by the price for a single quantity of this product. This ‘single unit’ price must reflect the price after any relevant discount is applied but prior to any taxes or additional charges are applied. The value must be a float, no thousand separator is allowed, and finally the decimal place has to be a standard dot character, for example: *1083.29*. - `{{productQuantity}}` must be replaced by the number of the unique product purchased in the same order, for example: *1*. - `{{productSku}}` is optional but can be used to record the product’s SKU, otherwise leave it blank. The parameter value has to be URL-encoded. - `{{commissionGroupCode}}` must be replaced by the [commission group code](/developers/docs/commission-groups) the product in question belongs to, which additionally has to match the breakdown you will have declared in `AWIN.Tracking.Sale.parts`. If you don’t map products to specific commission groups, or you’re an Awin Access customer, then just populate with a static *DEFAULT*. - `{{productCategory}}` is optional but can be used to record the category the product belongs to, otherwise leave it blank. The parameter value has to be URL-encoded. - `{{customParameter1}}` should be replaced by the first value to be associated with the Transaction in question. The parameter value has to be URL-encoded. - `{{customParameter2}}` should be replaced by the second value to be associated with the transaction in question. The parameter value has to be URL-encoded. ### Example multiple products ```plaintext &bd[0]=AW:P|{{advertiserId}}|{{orderReference}}|{{productId}}|{{productName}}|{{productItemPrice}}|{{productQuantity}}|{{productSku}}|{{commissionGroupCode}}|{{productCategory}}&bd[1]=AW:P|{{advertiserId}}|{{orderReference}}|{{productId}}|{{productName}}|{{productItemPrice}}|{{productQuantity}}|{{productSku}}|{{commissionGroupCode}}|{{productCategory}}&bd[2]=AW:P|{{advertiserId}}|{{orderReference}}|{{productId}}|{{productName}}|{{productItemPrice}}|{{productQuantity}}|{{productSku}}|{{commissionGroupCode}}|{{productCategory}}&p1={{customParameter1}}&p2={{customParameter2}} ``` ### Example ```xml ``` > [!NOTE] > Note > > Pipes are forbidden characters inside the values of `orderReference`, `productId`, `productName`, `productSku`, `productCategory`. --- A completed sale, order, or lead.