Magento 2 Google Enhanced Ecommerce Tracking
Table of Contents
- Real Time Event
- Backend Order Tracking in Google Analytics
- Shopping Behaviour
- Checkout Behaviour
- Product Performance
- Sales Performance
- Product List Performance by Category.
- Installation via app/code: Upload the content of the module to your root folder. This will not overwrite the existing Magento folder or files, only the new contents will be added. After the successful upload of the package, run below commands on Magento 2 root directory.
php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy
- Installation via Composer: Please follow the guide provided in the below link to complete the installation via composer.
Go to Admin > Stores > Configuration > Scommerce Configuration > Google Universal Analytics
- Enabled – Select “Yes” or “No” to enable or disable the module.
- License Key – Please add the license for the extension which is provided in the order confirmation email. Please note license keys are site URL specific. If you require license keys for dev/staging sites then please email us at [email protected]
- Account Id – Enter your Google Account Id.
- Anonymize Ip – Sets the parameter anonymize in tracking. If set to yes, tells Google Analytics to anonymize the information sent by the tracker objects by removing the last octlet of the IP address prior to its storage.
- Enable User Id – Enable/Disable User Id feature. Make sure this feature is enabled in Google Analytics first before enabling in Magento. For more information click here
- Domain Auto – Enable/Disable to show ‘auto’ as domain name, when turned off, it shows the domain name itself.
- Linker Enabled – Enable/Disable the linker plugin to link cross domains. For more information click here.
- Domains to Link – Add domain names or regular express for example ‘destination.com’, ‘dest3.com’ or /^example\.(com]|de|nl)$/ For more information click here.
- Linker Accounts Enabled – Enable/Disable the linker accounts.
- Base – Set “Yes” if you send base order data.
- Ajax Add to Basket Enabled – Set “Yes” if you have AJAX add to basket enabled on your website.
- Enable Enhanced Ecommerce – Select “Yes” to enable the enhanced ecommerce tracking.
- Steps – You can select multiple steps here, these steps correspond to Magento onepage standard checkout steps. Also make sure you add these same steps in Google Analytics under Ecommerce settings by turning Enhanced E-commerce on.
- Brand Attribute – You can select product attribute which you can use to set your brand names. This will be passed to Google for further reporting.
- Brand Name – You can also pass hard coded brand name using this configuration settings.
- Send Transactional Data Offline – Set “Yes” to send data on order creation only. This feature could be useful if your payment gateway show their own success instead of Magento order confirmation page.
- Send Transactional Data Only on Invoice Creation – Set “Yes” to send data on invoice creation only. This feature could be useful if you take either payment on dispatch or your payment gateway show their own success page instead of Magento order confirmation page.
- Send Phone or Admin Orders – Enable this feature only if you want to send admin or phone orders on order creation.
- Source – You can add your source here to pass this to Google for admin orders.
- Medium – You can add your source here to pass this to Google for admin orders.
- Send Product Impression on Scroll – Enable this feature when you have loads of products on product listing / category page.
- Product item class on category / product listing page – Make sure this product class item heirarchy is as unique as possible for example for luma theme you can use div.products ol.product-items li.product-item
- Debugging – Set “Yes” to generate GA.log in var/log directory to log all transactional data which we send to Google using measurement protocol.
- 1.Click Admin at the top of any Analytics page.
- 2.Select the view for which you want to enable Enhanced E-commerce reporting.
- 3.In the view column, click E-commerce Settings.
- 4.Under Step 1, Enable E-commerce, set the status to ON.
- 5.Click Next Step.
- 6.Under Step 2, Enhanced E-commerce Settings, set the status to ON. When you turn this option on:
- You can see the Enhanced E-commerce reports in the conversions section.
- The older, older category of E-commerce reports is no longer available.
You can turn this option off to restore the older category of E-commerce reports.
- Optionally, enter labels for the checkout steps that you have defined in your Magento steps configuration. Please see screenshot below for reference
- Click Submit.
- Real Time Event - You can view the tracked events from GA > Realtime > Events.
- Backend Order Tracking in Google Analytics - You can track admin orders by selecting "Yes" for "Send Phone or Admin Orders" from Admin > Stores > Configuration > Scommerce Configuration > Google Universal Analytics > Enabled Enhanced Ecommerce - "Yes".
- Shopping Behaviour - You can see the shopping behaviour from GA > Conversion >Ecommerce >Shopping Behaviour.
- Checkout Behaviour - You can see the checkout behaviour in GA with billing & shipping method, payment method and transactions details from GA > Conversion
> Ecommerce > Checkout Behaviour.
- Product Performance - To view the product performance go to GA > Conversion > Ecommerce > Product Performance.
- Sales Performance - To view tracked sales performance go to GA > Conversion > Ecommerce > Sales Performance.
- Product List Performance by Category - You can view the product list performance from GA > Conversion >Ecommerce >Product List Performance.
- Home Page with Tags - In Tag Assistant tool you can see the fired tags.
- GA - UA Tracking Code - In the below image you can see the UA tracking id's added from Admin > Stores > Configuration > Scommerce Configuration > Google Universal Analytics > Account Id - UA -33387561-9.
If you have a question related to this extension please check out our FAQ Section first. If you can't find the answer you are looking for then please contact [email protected].