GA4 dimension "Signed in with user ID" disabled
Asked Answered
T

2

7

After configure the google analytics property using GA4 instead of UA, I've seen there is something wrong with the user Id dimension. As you can see in the following image seems like GA4 is not receiving data with the user_id property so it is unable to filter by the property. By the way I'm referring to this property I'm using a Reporting identity option called By User-ID and device.

user ID dimension disabled

Seems like I have something wrong on my configuration, however when I use the DebugView tool of GA4 I can see the user_id is properly sent: enter image description here

So I'm not sure what's going on here. Why is Signed in with user ID dimension disabled?

Tinaret answered 11/3, 2021 at 12:27 Comment(0)
T
4

One day after "Signed in with user ID" is enabled without any additional configuration change. So it seems like it just needed some time to fit with data I guess.

Tinaret answered 12/3, 2021 at 7:48 Comment(1)
Are you you passing the user_id from GTM to GA4 as Fields to Set or as User Properties under the GA4 tag configuration? I believe the documentation only mentions to set it as Fields to Set... But the docs are incredibly lacking. Thank you so muchShandishandie
C
1

I was having problems with getting the user ID to send to GA4.

What resolved it for me was ensuring that it was always the absolute very first thing pushed to the dataLayer. For some reason if it was pushed "late", it would not be sent with ANY tracking events - even tracking events that occurred long after the userID was added to the dataLayer weren't working.

So, if anyone else is having trouble with this, try making sure your userID is set immediately when dataLayer is initialized, and before GA4 or GTM scripts are loaded:

window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
    user_id: "your_user_id",
});
Chris answered 17/3, 2023 at 18:38 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.