Identified users being merged into one User Profile. Why?

  • 13 January 2021
  • 3 replies

Hey All,

I am hoping someone can help, I am using the NPM SDK to integrate Mixpanel into my website.

I am currently doing everything the documentation is telling me, when an account is created I am calling `alias()` and when a user logs in I am calling `identify()`.

From what I can see all of the data is being sent to Mixpanel correctly but what is confusing me is how I view the users within Mixpanel.

What I am aiming for is having an individual User Profile within Mixpanel for each account I have on my website, when “User A” logs in to the website I expect to see “User A” in Mixpanel, the same for “User B” and so on.

What I am actually seeing is one singular User Profile, this User Profile has all of the identities and alias’s attached to it and all of the custom user ids that I have sent through the `identify()` function are all attached to this one User Profile under the distinct id. I believe you call this a cluster?

I would like to know how I can make it so that each user id in my system associates with only a singular User Profile in Mixpanel.

Thanks in advance for any help you can provide.


3 replies

Userlevel 3
Badge +2

Hello  @lukehillonline, can you share more details on how and where you are calling alias and identity and any custom UUID being used for identification such as email or id from backend?


Hey @Muffaddal Qutbuddin  Thanks for coming back to me.

I am using Amazon Cognito on my website for user management. Cognito provides functions for creating accounts and logging people in as a part of the JavaScript SDK.

What I am doing in my code is waiting for a successful response of the account creation and at that point I am using the users unique Cognito user ID as an identifier when calling `alias()`.

I then do the same with a successful response from Cognitos login function and at that point I sent `identify` with the same unique Cognito user ID.

The Cognito user IDs are always unique to a particular user and never change so I know they are safe to use as a unique identifier in Mixpanel.

I think I have solved the issue now by calling `reset()` when a user logs out, but I generally found it very confusing that whenever I called `alias()` with a completely new and unique ID, Mixpanel was still lumping it together under one distinct ID

Userlevel 3
Badge +2

@lukehillonline  good to know you found the solution. Also to let you know with mixpanel’s new identity merge you don’t need to call alias at all. identity() call will do all the trick for you. 

see here for more details: