How to enable Google Analytics in SharePoint 2013 /Office 365?
Let’s you want to integrate google analytics code in your SharePoint 2013 /Office 365 Environment. The solution is simple. You just need to insert the following google analytics code in to SharePoint Master Page.
1. Go to Site Settings.
2. Navigate to Galleries and Select the Master Page and layouts.
3. Choose the master page which you use and place the below code in the <head> tag .
4. Make sure that you publish your new Master Page
<script>
(function(i,s,o,g,r,a,m){i[‘GoogleAnalyticsObject’]=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,’script’,’//www.google-analytics.com/analytics.js’,’ga’);
ga(‘create’, ‘UA-63399923-2’, ‘auto’);
ga(‘send’, ‘pageview’);
</script>
Please do visit my another articles on
Import CSV contents into SharePoint 2013 using PowerShell
Enable the filtering by Content Type in SharePoint 2013/ Office 365
Happy SharePointing 🙂