Set custom user properties to identify static or slowly changing attributes of your users, such as "spender=true", "profession=engineer", or "favorite_team=Real Madrid". User properties are effectively sticky event parameters.
You can see user properties in the Realtime overview and other reports. For example, you can create comparisons with user properties, e.g. see how the game-play habits of spenders differ from non-spenders.
Each Google Analytics 4 property can have up to 25 uniquely named (case-sensitive) user properties.
Set a user property
Set a user property by calling gtag('set')
(websites), setUserProperty
(Android), or setUserPropertyString
(Objective C/iOS) in your website or app.
Register a user property
Before you can see your user property in reports, you need to register it.
- In Analytics, navigate to your Google Analytics 4 property.
- In the left navigation, click User Properties.
- Click NEW USER PROPERTY.
- Enter a name and description for the user property, then click CREATE.
Archive user properties
If you have reached your limit of 25 user properties and need to create new ones, you can archive the ones that are no longer relevant, and then after 48 hours, create a new one. During the first 48 hours after archiving a user property, you can restore it. After 48 hours, the user property is permanently archived.
To archive a user property:
- In Analytics, navigate to your Google Analytics 4 property.
- Click User Properties.
- In the row for that property, click
> Archive.
To restore a user property during the 48 hours after archiving, you set and register a new property with the same name per the instructions in the preceding section.
Related resource
Learn about automatically collected user properties.