1. Create dashboards which provide you transaction reports
2. Traffic monitoring / Page visists on each pages
3. Analysis on different customer segments
4. Trace key word searches
5. Many more...
You can use bellow steps to integrate your Gmail account and Google Analytics with your web site.
Step 1. Login to your Gmail account
Step 2. Then browse Google Analytics page. Ex : https://analytics.google.com/analytics/web/
Step 3. Mention your analytic name
Step 4. Select your traffic source. For me it is a web site. So i selected web
Step 5. Link you web site. Now you will be getting your web site tracking ID
Step 6. Accept Terms and Conditions
Step 7. Find your script segment. You have to embed this script on the top of your header page.
<!DOCTYPE html> <html> <title> <head> <meta charset="UTF-8"> <script async src="https://www.googletagmanager.com/gtag/js?id=UA-154006826-1"></script> <script> window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'UA-154006826-1'); </script> <script> function sendData(){ var paged_products_array = []; var name="iphone-x"; var amount="100.00"; var id="105031"; var brand="apple"; var category="mobile"; var varient="x"; var qty="1"; var obj = { name : name , id : id, price : amount, brand: brand, category: category, variant : varient, quantity : qty }; paged_products_array.push(obj); var ecomOb = { products : paged_products_array } var impressions = JSON.stringify(ecomOb); console.log("Analytics Remove Parameters-->"+impressions); dataLayer.push({ 'event': "productDetail", 'ecommerce': { 'detail': JSON.parse(impressions) } }); } </script> </head> </title> <body> <input type="button" value="send-analytics" onclick="sendData()"/> </body> </html>
No comments:
Post a Comment