Google Analytics (UA) plugin
There are two Google Analytics data sources, this article covers the v3 version which is most frequently referred to as Universal Analytics (UA). Users are being forced from UA to the newer GA4 with UA being end-of-life mid-2023. See Google Analytics GA4 plugin
The Google Analytics plugin allows you to visualize your website data.
Click the following link for additional content such as blogs, videos, use cases, and more:
Adding a data source
To add a data source click on the + next to Data Sources on the left-hand menu in SquaredUp. Search for the data source and click on it to open the Configure data source page.
Before you start
Enable the Google Analytics APIs
In the GCP console select your project and ensure that the Google Analytics Data API is enabled.
Configure the GCP Service Account
- Create a new Service Account, or edit an existing account.
See GCP - Creating and managing service accounts. - Ensure the account has the role Viewer by adding the role Basic > Viewer.
See GCP - Grant a single role. - Create a new key for the Service Account using the key type JSON. Download the JSON file as you will need to copy information from this JSON file when adding the data source next.
See GCP - Creating service account keys.Make sure to store the key file securely, because it can be used to authenticate as your service account.
Configuring the data source
- Open the JSON file that you downloaded when creating the key.
- Copy and paste the clientEmailfrom the JSON file into the data source form.
- Copy and paste the private_key from the JSON file into the data source form (everything between the quotes).
Restrict access to this data source:
Optionally, enable this toggle if you only want certain users/groups to have access to the data source, or those with the permission to link it to new workspaces. See data source access control for more information.The term data source here really means data source instance. For example, a user may configure two instances of the AWS data source, one for their development environment and one for production. In that case, each data source instance has its own access control settings.
By default, Restrict access to this data source is set to off. The data source can be viewed, edited and administered by anyone. If you would like to control who has access to this data source, switch Restrict access to this data source to on.
Use the Restrict access to this data source dropdown to control who has access to the workspace:
- By default, the user setting the permissions for the data source will be given Full Control and the Everyone group will be given Link to workspace permissions.
- Tailor access to the data source, as required, by selecting individual users or user groups from the dropdown and giving them Link to workspace or Full Control permissions.
- If the user is not available from the dropdown, you are able to invite them to the data source by typing in their email address and then clicking Add. The new user will then receive an email inviting them to create an account on SquaredUp. Once the account has been created, they will gain access to the organization.
- At least one user or group must be given Full Control.
- Admin users can edit the configuration, modify the Access Control List (ACL) and delete the data source, regardless of the ACL chosen.
See Access control for more information.
Click Test and add to validate the data source configuration. SquaredUp will now attempt to connect to SquaredUp using the provided authentication method.
- Testing passed – a success message will be displayed and then the configuration will be saved.
- Testing passed with warnings – warnings will be listed and potential fixes suggested. You can still use the data source with warnings. Select Save with warnings if you believe that you can still use the data source as required with the warnings listed. Alternatively, address the issues listed and then select Rerun tests to validate the data source configuration again. If the validation now passes, click Save.
- Testing Failed – errors will be listed and potential fixes suggested. You cannot use the data source with errors. You are able to select Save with errors if you believe that a system outside of SquaredUp is causing the error that you need to fix. Alternatively, address the issues listed and then select Rerun tests to validate the data source configuration again. If the validation now passes, click Save.
You can edit data source configurations at any time from Settings > Data Sources.
Testing and troubleshooting
If you encounter an error refer to the guidance or contact our support team in-app or via SquaredUp Support
Next steps
Page Views (UA)
Number of page views for this profile (view)
Sessions (UA)
Number of sessions for this profile (view)
Sessions by Page (UA)
Number of sessions for this profile (view)
Sessions by Social (UA)
Number of sessions for this profile (view)
Users (UA)
Number of unique visitors for this profile (view)