Google Analytics extension for Google Sheets Guide
If you have ever felt that the default Google Analytics interface is limiting you to view and explore the data of your website, then this post is for you.
If you work with the default Google Analytics interface, sooner or later you will want to view some data which is not offered by the build-in reports from GA. A classic example of this might be a pivot table with 2 or more custom dimensions, which cannot be viewed by default.
And for these specific cases, you can use the Google Analytics add-on extension from Google Sheets to view the data in any way you need.
1. How to install the Google Analytics extension
Open a blank spreadsheet and from the top menu, go to Add-ons / Get add-ons. In the window which appeared, type “Google Analytics” in the search bar and once the search results appear, click on the “Free” button from the right to install it.
After several seconds, the new add-on will be installed and you can access it from the Add-on menu.
2. How to configure the add-on to import data from Google Analyitcs
Go to Add-ons from the main menu, then navigate to “Google Analytics” then select “Create New Report”.
In the window that appeared, you need to enter a name for your report, select the account, property and view from which you want to get the data and then you need to enter the metrics and dimensions you want to import. After this click on “Create report” from the bottom.
After this a new sheet called “Report Configuration” will appear in which you can see the previous configurations you entered with some additional options like start date, end date, filter, segments, etc.
The following parameters need to be added in the configuration before you can run the query:
Report Name - In this field you need to enter the report name. It will also be the name of the sheet where the report data is written.
View ID - The ID of the Google Analytics view. You can get this value from the Google Analytics account admin.
Start Date - The start date for which you want to get Analytics data. The format can be as YYYY-MM-DD, or as a relative date (e.g., today, yesterday, or NdaysAgo where N is a positive integer).
End Date - The end date from which you want to get Analytics data. The format can be as YYYY-MM-DD, or as a relative date (e.g., today, yesterday, or NdaysAgo where N is a positive integer).
Metrics and dimensions - A list of metrics to query. Some examples include: ga:sessions,ga:bounces, ga:sessions. ga:bounces. The full list of dimensions and metrics and their valid combinations is available using the Dimensions and Metrics Explorer.
3. How to get data to Google Sheets
After we have configured the Google Analytics add-on, we need to run the query by going to Add-ons / Google Analytics / Run report. This will connect to Google Analytics and extract the data and save it in a new sheet with the same name as your report name.















