Google Analytics
Learn how to setup the connection between the app and Google Analytics.
On this page
Assuming you are already utilizing Google Analytics to track user activity on your website, distinguishing between website usage and app usage can be accomplished effortlessly. This guide assumes you have successfully set up GA4 for your app.
The developer part
In the event listener for the ready
event you should added the following line of code:
gtag('set', 'user_properties', {'startiapp': 'true'});
That’s it. Next, someone with access to Google Analytics should proceed with the following steps.
Setting up Google Analytics
Open Google Analytics. Navigate to the desired Analytics account.
Click the Admin icon.
Click “Custom definitions”.
Click the “Create custom dimension” button.
Create a new custom dimension by entering “startiapp” into the “Dimension name” field. Choose “User” in the “Scope” dropdown. Provide a description in the “Description” input field. Enter “startiapp” in the “User property” field. Click the “Save” button to create the custom dimension.
The setup for GA4 has now been completed to begin tracking app usage. It’s important to keep in mind that it may take a few hours for Google to start displaying the data from the app.