How does network_userid really work?

My production database shows many cases that more than an user_id matches with 1 network_userid. The below image is an example. I’m wondering how it can happen because there’re totally new users with different user_id and user_ipaddress

What tracker are you using? Also, how do you set the user_id values?

Assuming these are events from a front-end tracker, the network_userid gets set by the collector and is typically stored in the server-side cookie. When the tracker sends events back to the collector, this cookie gets included in the HTTP request headers. Cookies & Local Storage | Snowplow Documentation

If you’re using a server-side tracker, it might be that the network_userid is set manually. Here’s an example with Python tracker: Adding extra data: The Subject class | Snowplow Documentation

@vil in my case, im using front-end tracker, my user_id is identifier id of my system, as i understand, when there are other users login in to my site network_userid must be changed, but i got the same problem, did i miss anything ? thank you

Hi @Phuc_Nguy_n, the network_userid does not automatically change when users log in and out on the same browser. It is expected to see multiple user_id values belonging to the same network_userid when the same browser is used to log in and log out of several different accounts after each. Could this be the case in the data?

1 Like