The Plus Royal UI V3.6.1 template is free if you want to get it download here.. Download Free!

How To Add LazyLoad Google Analytics in Blogger ?

Please wait 0 seconds...
Scroll Down and click on Go to Link for destination
Congrats! Link is Generated
How To Add LazyLoad Google Analytics in Blogger ?


Now Google makes blog loading speed a ranking factor in search results, so we should optimize the loading of the blog. Here you can use Google PageSpeed Insights to find out why your blog is loading slowly.

Google analytics is one of the blog statistics tool with SEO elements, so we should keep it installed on our blog, we can use Lazy Load Script to overcome google analytics loading problem.

Usually Lazy Load is Often installed on images and Adsense. For example Lazy Load normally works to delay the loading of some items so that they are loaded until scrolling activity occurs and in this post I will share how to lazy load Google Analytics.

How To Add LazyLoad Google Analytics in Blogger

Step 1 :- First of All Login Your Blogger Account.
Step 2 :- Then Click on Setting Icon and Remove Google Analytics Property.
Step 3 :- Then Click on Theme Menu.
Step 4 :- Then Click on Edit Html
Step 5 :- Then find the provided old Google Analytics code and delete it.
<script async='async' src='https://www.googletagmanager.com/gtag/js?id=UA-xxxxxxx-x'/>
<script>
//<![CDATA[
  window.dataLayer = window.dataLayer || [];
  function gtag(){dataLayer.push(arguments);}
  gtag('js', new Date());
  gtag('config', 'UA-xxxxxxx-x');
//]]>
</script>
Step 6 :- Then find </body> and then paste the new lazy loaded Google Analytics code given.

<script type="text/javascript">
//<![CDATA[
var lazyanalisis=false;window.addEventListener("scroll",function(){(0!=document.documentElement.scrollTop&&false===lazyanalisis||0!=document.body.scrollTop&&false===lazyanalisis)&&(!function(){var e=document.createElement("script");e.type="text/javascript",e.async=true,e.src="https://www.googletagmanager.com/gtag/js?id=UA-163xxxxxx";var a=document.getElementsByTagName("script")[0];a.parentNode.insertBefore(e,a)}(),lazyanalisis=true)},true); window.dataLayer = window.dataLayer || [];function gtag(){dataLayer.push(arguments);}gtag('js',new Date());gtag('config','UA-163xxxxxx');
//]]></script>

Note :- Change the Google Analytics Tracker ID I've Marked

Step 7 :- Then Don't Forget to Click on Save and Then See The Result.

Conclusion :-

In this post I have shared with you all How To Add LazyLoad Google Analytics in Blogger. So how did you like this post and tell me by commenting. If you have any question then you can comment. Thanks for visiting our website.

Refrence :
Smart Tech Carry

Rate This Article

Thanks for reading: How To Add LazyLoad Google Analytics in Blogger ?:)

Conclusion

In this article, I have shared How To Add LazyLoad Google Analytics in Blogger ?. I hope you have liked it Please do share it with your friends and follow our blog for more.

Join our Telegram Channel to get the lastest posts updates daily. Thank you!

About the Author

Hello Friends, Welcome To Our Website. My Passion is to Share Knowledge With Everyone. Also I am a Youtuber | Blogger | Web Developer | Programmer

إرسال تعليق

Cookie Consent
We serve cookies on this site to analyze traffic, remember your preferences, and optimize your experience.
Oops!
It seems there is something wrong with your internet connection. Please connect to the internet and start browsing again.
AdBlock Detected!
We have detected that you are using adblocking plugin in your browser.
The revenue we earn by the advertisements is used to manage this website, we request you to whitelist our website in your adblocking plugin.
Site is Blocked
Sorry! This site is not available in your country.