# Login with a specific connection

**URL:** <https://community.auth0.com/t/login-with-a-specific-connection/8964>\
**Category:** Get Help\
**Tags:** connections\
**Created:** [December 13, 2017, 2:28pm UTC](https://community.auth0.com/t/login-with-a-specific-connection/8964 "2017-12-13T14:28:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![talzamir92](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@talzamir92](https://community.auth0.com/u/talzamir92)\
**Post date:** [December 13, 2017, 2:28pm UTC](https://community.auth0.com/t/login-with-a-specific-connection/8964/1 "2017-12-13T14:28:17Z")

</div>

I followed the Angular2 documentation and all is working just fine, except on thing - I can’t choose my desired connection properly,  
On the Auth0 sandbox I disabled all connections except the one I want. The issue is, that when the user is redirecting to the login page, first he’s redirected to the default Auth0 login page, and than there is a button that says “Log in at MY-WANTED-CONNECTION-NAME”. I want the user to move directly to my connection login page, without the need to click this button on his way,

This is how the webAuth is defined in my code:

```
  auth0 = new auth0.WebAuth({
    clientID: MY-CLIENT-ID,
    domain: MY-DOMAIN-URL,
    audience: MY-API,
    connection: MY-WANTED-CONNECTION,
    responseType: 'token id_token',
    redirectUri: CALLBACK-URL,
    scope: 'profile'
  });

```

---

<div class="post-metadata">

**Author:** ![jmangelo](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/jmangelo/32/7923_2.png) [@jmangelo](https://community.auth0.com/u/jmangelo)\
**Post date:** [December 20, 2017, 9:30pm UTC](https://community.auth0.com/t/login-with-a-specific-connection/8964/2 "2017-12-20T21:30:05Z")

</div>

You need to pass the connection as an option to the `authorize` method call and not as an option for the `WebAuth` constructor.

---

<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 2, 2018, 5:57am UTC](https://community.auth0.com/t/login-with-a-specific-connection/8964/3 "2018-03-02T05:57:46Z")

</div>


