Final Step:How and Where to Add this GTag Code on WordPress Site:
Copy this gtag code and put it under <head> tag of your site.
<!-- Global site tag (gtag.js) - Google Analytics --><script async src="https://www.googletagmanager.com/gtag/js?id=G-NE267K4Z50"></script><script> window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'G-NE267K4Z50');</script>
To add Ggtag code to a WordPress site under <Head>tag
There are several ways add Gtag code, but, I am going to tell you a most recommended method is, through the plugin
Go to WordPress Dashboard and click plugin>>New Plugin
This is one of the suitable plugins to add Gtag code
Then, click to install and activate it.
Now it is under settings in your WordPress dashboard
Then, Click the Insert Headers and Footers to add the Gtag Code.
Now, copy the code from the google analytics code area then, paste it "Scripts in Header"
And then, click Save. Now it is OK.
By this method, no problem, if you change your WordPress theme or update it. The Gtag Code is fixed.
Then, you can visit your google analytics tool to view visitors. For that, you can view your site same device with a different browser or a separate device. You can see the results.
WOW! visitors can see through google analytics on my site.
I think you can understand my tutorial. If not clear, please comment below, I will help you. As well as if you can't see visitor yet, please comment. I do my best to help you.
Thank you and Good Luck
I think this will help you
I am getting message to connect Exact Metrics. Which of these should be connected and if so I get an error for this to.
Thank you,
Diane
Thanks for offering this training, as it is badly neeeded.
The only problem with placing tracking code in the header.php of a website's WordPress theme is that the next time the theme is updated, the tracking code will be overwritten and disappear from the website.
The users need to use an SEO plugin or... at the very least, the headers and footers plugin like that which is shown here: Why Use Headers and Footers Plugin Feel free to update your training to include this information, as I'm sure others will be glad for the additional info.
Hope this helps you.