User fields & dimensions

User Fields & Dimensions

Published:

Written by:

The user fields contain information that uniquely identifies the user associated with each event.

While Google Analytics collects many of these values automatically, some of them, such as user_id and user_properties, require manual implementation. Therefore, the presence of these fields in your data may vary depending on your setup and configuration.

Field NameData TypeDescriptionExample Values
user_pseudo_idSTRINGThe pseudonymous id for the user (sometimes referred to as client ID)2027626168.1665510689
user_idSTRINGThe unique ID assigned to a user.
Note: this will only be present if passed in by your site or app
An ID unique to your business
is_active_userBOOLEANIndicates whether the user was active or inactive at any point in the calendar daytrue or false
user_first_touch_timestampINTEGERThe time (in microseconds) at which the user first opened the app or visited the site1690544075596000
user_propertiesRECORDUser property keys and values associated with the event – see User properties for more infoThese will be unique to your business
user_ltv.revenueFLOATThe Lifetime Value revenue of the user10.00
user_ltv.currencySTRINGThe Lifetime Value currency of the userUSD, GPD, EUR, etc.
privacy_info.analytics_storageSTRINGIndicates whether or not the user has opted-in to analytics storage
Note: this is feature of Google’s consent mode and will be dependant on your implementation
Yes or No
(if No then user_pseudo_id will be null)
privacy_info.ads_storageSTRINGIndicates whether or not the user has opted-in to ads storage
Note: this is feature of Google’s consent mode and will be dependant on your implementation
Yes or No
privacy_info.uses_transient_tokenSTRINGIndicated if a web user has denied Analytics storage and the developer has enabled measurement without cookies based on transient tokens in server dataYes or No

Sample user fields query

Select the user fields you need from the below query.

For more information on how to extract specific values from the user_properties field check out the tutorial Extract GA4 user properties in BigQuery.

SELECT
  user_pseudo_id,
  user_id,
  is_active_user,
  user_first_touch_timestamp,
  user_properties,
  user_ltv.revenue,
  user_ltv.currency,
  privacy_info.analytics_storage,
  privacy_info.ads_storage,
  privacy_info.uses_transient_token
FROM `<project>.<dataset>.<table>`

Important Note: Make sure you replace the placeholders within the WHERE clause with the specific values for the table you are working with. For example, if you want to extract data for January 31st 2021 from the e-commerce sample dataset, use the following values:

  • <project> should be replaced with bigquery-public-data
  • <dataset> should be replaced with ga4_obfuscated_sample_ecommerce
  • <table> should be replaced with events_20210131

Ensure that you substitute these placeholders with your actual project, dataset, and table names when executing the queries.


For details and examples of other fields & dimensions see:

New to the GA4 BigQuery export? Check out our free introductory guide.

X