Search code examples
google-analyticsgoogle-bigquerygoogle-tag-managergoogle-analytics-apigoogle-analytics-4

Can I add custom parameters to 'items' in GA4?


I'm using GA4 and I want to add some custom parameters to 'items' parameter in some events.

Reading the documentation I found this reference that have this observation: "Item parameters can have a maximum of 10 custom parameters.". Reference: https://developers.google.com/analytics/devguides/collection/protocol/ga4/sending-events?client_type=gtag#limitations

I have not found in documentation some example of how to use custom parameters in 'items'.

When I tried to pass some custom parameters into 'items', the request built by the GA4 GTM Template Tag had this format in Query String Parameters:

pr1: id24~nmexampleName~pr12345~lnlistName~k0customKey00~v0customValue00~k1customKey01~v1customValue01

However, I have not found this custom keys and values information into BigQuery.

There is a way to use custom parameters inside 'items' and then use this data on BigQuery?


Solution

  • Unfortunately, Google decided to roll out an unfinished product out there. And advertise it heavily. And scare people with UA deprecation talks. GA4 still lacks the Product scope for custom dimensions, among other things. Therefore, we have to hack around for now. Here are some options:

    1. If UA is still up at the moment you're reading this, then use UA instead of GA4 for analysis while waiting for GA4 to implement product-scoped CDs.
    2. Stuff extra dimensions into existing dimensions and then split them during ETL.
    3. Just take the unused default product dimensions if you don't use them, like the item_category[2-5]
    4. Have backend product ids logged in items to then backfill/enrich the BQ data from your backend.
    5. Wait till GA4 adds the product scoped CDs.