How to Add Google Analytics Tracking to a Website - Chartio

文章推薦指數: 80 %
投票人數:10人

There are a few ways to add Google Analytics tracking code to your website. Adding Google Analytics to your website enables you to track the number of ... DataTutorials WhatisChartio? Close ThereareafewwaystoaddGoogleAnalyticstrackingcodetoyourwebsite.AddingGoogleAnalyticstoyourwebsiteenablesyoutotrackthenumberofvisitorstoyoursite,thesearchkeywordstheyusetofindyoursite,thetimespentonyoursite,goalconversionandmuchmore. Afewhousekeepingitemsbeforewemoveforward,thistutorialassumesthatyoualreadyhaveaStandardGoogleAnalyticsaccountandnotaGoogleAnalytics360account.Second,thatyouhavealreadysetupapropertyinGoogleAnalytics,whichallowsyoutogenerateatrackingID(moreonthislater). Withthatsettled,we’llexploretwowaystoaddGoogleAnalyticscodetoyourwebsite. GoogleAnalyticsTrackingCode Thefirststepyou’llneedtodoisfindyourtrackingID,whichisauniqueIDcreatedforyourGoogleAnalyticsaccount. TogetyourtrackingID,followthesesteps: LogintoyourGoogleAnalyticsaccount Onthebottomleft-handsideofthepage,clickAdmin FromtheleftcolumntitledAccount,selectanaccountfromthedropdownmenu FromthemiddlecolumntitledProperty,selectapropertyfromthedropdownmenu UnderthePropertycolumn,clickTrackingInfo>TrackingCode Yourwebsite’suniquetrackingIDisshownatthetopofthepageunderTrackingIDandstartswithUA Onceyou’veidentifiedyourtrackingID,you’llneedtogetyourtrackingcodesnippet,whichcanbefoundonthispageastheGlobalSiteTag(gtag.js).Thegtag.jsisthetrackingcodeforthisspecificpropertyandyou’llneedtocopyandpastethiscodetoeverywebpageyouwanttotrackonyourwebsite. Tocopyandpasteyourgtag.js,followthesesteps: Copythegtag.jsshownonthepage(exampleshownbelow) ReplacetheGA_TRACKING_IDwithyouruniquetrackingIDprovidedbyGoogleAnalytics Pastethecodesnippetrightafterthe

tagoneachpageofyoursitethatyou’dliketotrackinGoogleAnalytics Keepinmindthatgtag.js(launchedin2017)isanewer,moreexpandedversionofanalytics.js. GoogleTagManager YoucanalsouseGoogleTagManagertoaddtheGoogleAnalyticscodetoyourwebsite.GoogleTagManagerisafreetoolandisusefulforwebsitesthatusemultipleanalyticsoradvertisingperformancetoolsfrommultiplecampaigns. ToinstallGoogleAnalyticscodeviaGoogleTagManager(GTM),followthesesteps: (Source:GoogleAnalyticsDocumentation) InGTM,selectCreateTagandchooseGoogleAnalytics ThenselectUniversalAnalytics Nameyourtag,preferablysomethingrelatedtoGoogleAnalytics(likeGA).AddyourGoogleAnalyticspropertyIDorgaPropertyvariable. ChoosetheTrackType(i.e.PageView) ChooseyourfiringtriggerssuchasAllPages,whichthetagwillfirethetrackeroneverypageofyourwebsite Gtag.jsorGoogleTagManager? IfyourwebsiteisalreadyusingGoogleTagManager,thengtag.jsisnotnecessaryandcontinuetouseGTM.SinceGTMinherentlycombineseventdatafromGoogleAnalyticsandGoogleAdwords,it’sbesttokeepitrunningifit’salreadyinplace. However,ifyouhaven’tinstalledGTMandarenotplanningoninvestinginGoogleAdwords,usingthegtag.jsmaybebeneficialtoyourwebsite.Thegtag.jstagmakesthetrackingprocesseasierby: StreamliningtheinstallationprocesstogetGoogleAnalyticscodeonyoursitefaster Allowingyoutosendeventdatatomultipletoolsasonce Keepingalltrackingtagsinonceplaceinyourwebsitecode Eitherway,werecommendthatyouaddGoogleAnalyticstoyourwebsite,soyoucankeeptrackofallyoureventdata. Contents GoogleAnalyticsTrackingCode GoogleTagManager Gtag.jsorGoogleTagManager? Freedownload similararticles CohortAnalysisPrimer Onewayofdiggingdeeperintoyourdataisthroughacohortanalysis.Inthisarticle,youwilllearnwhatcohortsareandhowtheycanbeusedtogenerateinsights. WhataretheMostUsefulGoogleAnalyticsReportsforE-Commerce GoogleAnalyticsisaverypowerfulwebanalyticstoolthatcanhelpyouunderstandmanyfacetsofyourbusiness.ThistutorialwillgooverthemostusefulGoogleAnalyticsreportsforane-commerceorganization. WhatisMarketingAnalytics Marketinganalyticsisthepracticeofcollecting,managing,andmanipulatingdatatoprovidetheinformationneededformarketerstooptimizetheirimpact. GetademoofChartio Inthis15minutedemo,you’llseehowyoucancreateaninteractivedashboardtogetanswersfirst. Learntheimportanceofagreatdatastack. Downloadourfreeclouddatamanagementebookandlearnhowtomanageyourdatastackandsetupprocessestogetthemostourofyourdatainyourorganization. DiscoverwhyourcustomersrateChartio#1 Signupfora14-dayfreetrial 14dayfreetrial Nocreditcardrequired SOC2compliant 25+directdatasourceconnections


請為這篇文章評分?