Installation:
1-Open your SharePoint 2013 site collection or your public website
2-Rename the URL in the browser (Login as needed with a site collection administrator / your admin account):
Current URL: https://srkk.sharepoint.com/sites/ePortal/
Rename to: https://srkk.sharepoint.com/sites/ePortal/_catalogs/solutions
3-Select Upload Solution
4-Select Browse…
5-Click Open and OK to upload the solution.
6-Select Activate to install the solution.
7-Now, verify the activation was successfully.
8-Finally you have to add your Google Analytics code. For that you can open Site Settings.
9-There is a new menu entry point under Site Collection Administration which is called Google Analytics.
10-Paste the google analytics code into the red square and press OK.
11-Activate the SharePoint Server Publishing
12-It will reflect to your google analytics account as shown below