What is user_id and why would I want to use it?
updated 7 months ago
Tracking signups correctly is a key step in your marketing funnels and identifying those new users is important so their information is available to your marketing, sales and support teams.
And a User ID is required to uniquely identify each user in your app and create respective contacts in Gist. Remember that a User ID cannot change and is optional. We strongly suggest setting a User ID once the user has created an account, logged in, or is otherwise identified in your product.
- A user can only have one User ID and if it is changed, then Gist will treat that new User ID as a different user. It is fine to not set a User ID -- you should not set a User ID for anonymous users
- If you do not have a system of assigning User IDs (either client or server-side) then skip this section
Assigning User IDs
Products that have some kind of login system can track users so Gist can be track them consistently across different browsers or devices. Though assigning User IDs is optional, we recommend that products with a login system or a UUID (unique user identifier) system assign a User ID.
With a User ID, Gist can match events across multiple devices under the same user (same User ID). Furthermore, a User ID does not need to be assigned immediately. A user's event data will be merged on the backend so that all anonymous events up to the point of User ID assignment will be connected to the assigned User ID (assuming the browser session is consistent).
- Do not set User ID if there isn't one. For example, setting a User ID to the string 'None' to multiple users will group all events under that 'None' User ID together (e.g. any user with the 'None' User ID is assumed to be the same single user). You can always set the User ID later, and Gist has a built-in logic that will merge the anonymous events to the later identified user.
- Do not assign a User ID that might change. If someone’s email can change within your app, then it is not a good idea to set it as a User ID as Gist will mark the person as a new user if they change their email.
- User IDs are case-sensitive. If you set a user's User ID with a different casing, that user will have two separate profiles.
- Assigning User IDs properly can be tricky if you have a system that does it server-side. If you feel that you are running into issues assigning User IDs, then please contact us via in-app chat.
If you have any further questions, please start a Live Chat. Just "Click" on the Chat Icon in the lower right corner to talk with our support team.