# Account Linking - Primary & Secondary account

**URL:** <https://community.auth0.com/t/account-linking-primary-secondary-account/79660>\
**Category:** Get Help\
**Tags:** api, rules, login, auth0\
**Created:** [March 10, 2022, 2:09pm UTC](https://community.auth0.com/t/account-linking-primary-secondary-account/79660 "2022-03-10T14:09:37Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![carla](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/carla/32/35235_2.png) [@carla](https://community.auth0.com/u/carla)\
**Post date:** [March 10, 2022, 2:09pm UTC](https://community.auth0.com/t/account-linking-primary-secondary-account/79660/1 "2022-03-10T14:09:37Z")

</div>

Hi, I want to implement an account linking , I already add the extension but I don’t where I need to define primary and secondary account as this mentions [User Account Linking](https://auth0.com/docs/manage-users/user-accounts/user-account-linking) . Also need to add once the account linking is done is possible to redirect the logged in user to one of the apps ?

Thanks

---

<div class="post-metadata">

**Author:** ![lihua.zhang](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/lihua.zhang/32/39683_2.png) [@lihua.zhang](https://community.auth0.com/u/lihua.zhang)\
**Post date:** [March 10, 2022, 6:41pm UTC](https://community.auth0.com/t/account-linking-primary-secondary-account/79660/4 "2022-03-10T18:41:47Z")

</div>

Hi @carla ,

Welcome back to the Auth0 Community!

[This article](https://auth0.com/docs/manage-users/user-accounts/user-account-linking/suggested-account-linking-server-side-impl) explains the steps regarding User Account Linking: Server-Side Implementation.

Basically, with the `Auth0 Account Link extension` installed, the user will experience the following:

Let’s say, [John.Doe@xxx.com](mailto:John.Doe@xxx.com) is a verified user and has the Username-Password Authentication. And your tenant has the Google Social Authentication set up.

If this user also has a Google Account with the same email [John.Doe@xxx.com](mailto:John.Doe@xxx.com), when he tried to log in to an Application in this tenant, instead of entering username and password, he clicked on Google, then this account Link screen will popup.

 ![image](https://global.discourse-cdn.com/auth0/original/3X/2/f/2fe24c9afa9eb44a6f6ef4320709c527e03f51ba.jpeg)

There are two options.

1. I want to skip this and create a new account.
2. Continue

By selecting option 1, a new Google Auth account will be created for this email. Otherwise, the existing Username-password account will be linked with the Google account, with the existing account as the primary account and the new account as the secondary account.

Under the user settings → Raw Json tab, both primary and secondary accounts details are associated with the email.

And regardless users chose to link accounts or create a new account, they will be re-directed to the App.

Hopefully, the above details answered your query!

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [March 25, 2022, 6:42pm UTC](https://community.auth0.com/t/account-linking-primary-secondary-account/79660/5 "2022-03-25T18:42:01Z")

</div>

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.
