In my project, I am using both Google and GitHub as OAuth providers. Suppose a user signs up using the Google provider, and later tries to sign in using the GitHub provider with the same email address.
- Does Appwrite automatically merge these accounts?
- Or does it create two separate accounts for the same email?
- If merging is possible, how does Appwrite handle the provider UID and existing session data?
- Yes
- No
- the provider UID is stored in the new session and identity.
Maybe this will also give you more info: https://appwrite.io/docs/products/auth/identities
const session = await account.createSession({ userId, secret });
console.log("session", session);
output :
"$id": "68c1a980e5b89dddecc4",
"$createdAt": "2025-09-10T16:38:25.326+00:00",
"$updatedAt": "2025-09-10T16:38:25.326+00:00",
"userId": "68c184f10009322ad7f5",
"expire": "2026-09-10T16:38:25.518+00:00",
"provider": "oauth2",
"providerUid": "",
"providerAccessToken": "",
"providerAccessTokenExpiry": "",
"providerRefreshToken": "",
"ip": "172.20.0.1",
"osCode": "WIN",
"osName": "Windows",
"osVersion": "10",
"clientType": "browser",
"clientCode": "CH",
"clientName": "Chrome",
"clientVersion": "140.0",
"clientEngine": "Blink",
"clientEngineVersion": "140.0.0.0",
"deviceName": "desktop",
"deviceBrand": "",
"deviceModel": "",
"countryCode": "--",
"countryName": "Unknown",
"current": true,
"factors": [
"email"
],
"secret": "",
"mfaUpdatedAt": ""
}```
here `providerUid` is blank.
Recommended threads
- Getting current user has been blocked
Getting current user has been blocked error while signing in the appwrite console. Got this during I am testing with the my saas web project. Please help to unb...
- vorafy.studio domain already exists erro...
My domain vorafy.studio is stuck/locked from a previously deleted project. I created a new project but can't add the domain — getting 'already exists' error. Pl...
- Custom domain for Google Auth
Hello! I connected my custom domain to my Appwrite project, but I can't get the Google login/consent screen to show my domain instead of the Appwrite domain. I...