Statsig does not provide an inherent mechanism to distinguish between new and returning users within its SDK or API.
To differentiate between these user types, developers must implement their own logic to identify whether a user is new or returning. This can be achieved by setting a flag or property within the user's browser or device storage, such as a JavaScript cookie or a local storage flag for web applications, or leveraging device storage for mobile platforms.
Once this identification is made, the information should be included as a user attribute when logging events or checking feature gates with Statsig.
It is important to ensure that this user attribute is passed along with the user object to Statsig to maintain the distinction between new and returning users within the platform's analytics and feature management.