# Login with provided connection

**URL:** <https://community.auth0.com/t/login-with-provided-connection/123437>\
**Category:** Get Help\
**Tags:** identifier-first, login-experience\
**Created:** [December 20, 2023, 2:17pm UTC](https://community.auth0.com/t/login-with-provided-connection/123437 "2023-12-20T14:17:33Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![sufyan](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/sufyan/32/53400_2.png) [@sufyan](https://community.auth0.com/u/sufyan)\
**Post date:** [December 20, 2023, 2:17pm UTC](https://community.auth0.com/t/login-with-provided-connection/123437/1 "2023-12-20T14:17:33Z")

</div>

\<button onClick={() =\> loginWithRedirect({  
connection: “google-oauth2”  
})}\>Log In;

This doesn’t seems to work anymore, I want to login with google directly and do not want to show the auth0 default page with

---

<div class="post-metadata">

**Author:** ![dawid.matuszczyk](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/dawid.matuszczyk/32/74550_2.png) [@dawid.matuszczyk](https://community.auth0.com/u/dawid.matuszczyk)\
**Post date:** [December 30, 2023, 7:36pm UTC](https://community.auth0.com/t/login-with-provided-connection/123437/3 "2023-12-30T19:36:20Z")

</div>

Hi @sufyan

Welcome to the Auth0 Community!

Based on the response [here](https://community.auth0.com/t/pre-select-a-single-social-connection-to-skip-auth0-login-for-new-universal-login/115674/2) you should change your button function and add authorizationParams to the parameters.

```auto
onClick={() => loginWithRedirect({authorizationParams: {
                      connection: "google-oauth2"
                    }})}

```

Thanks  
Dawid

---

<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:** [January 13, 2024, 7:36pm UTC](https://community.auth0.com/t/login-with-provided-connection/123437/4 "2024-01-13T19:36:58Z")

</div>

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