# Custom Login with Springboot and Authorization Code Flow

**URL:** <https://devforum.okta.com/t/custom-login-with-springboot-and-authorization-code-flow/787>\
**Category:** Questions\
**Tags:** spring\
**Created:** [November 21, 2017, 4:20am UTC](https://devforum.okta.com/t/custom-login-with-springboot-and-authorization-code-flow/787 "2017-11-21T04:20:35Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![josh.hardy.ufen](https://avatars.discourse-cdn.com/v4/letter/j/dc4da7/32.png) [@josh.hardy.ufen](https://devforum.okta.com/u/josh.hardy.ufen)\
**Post date:** [November 21, 2017, 4:20am UTC](https://devforum.okta.com/t/custom-login-with-springboot-and-authorization-code-flow/787/1 "2017-11-21T04:20:35Z")

</div>

Is it possible to configure a custom UI login form instead of using the Okta login form with the Authorization Code flow?

I would like to have a route to login and host my own login form so I can customize the look and feel.

---

<div class="post-metadata">

**Author:** ![vijet](https://sea1.discourse-cdn.com/oktadev/user_avatar/devforum.okta.com/vijet/32/245_2.png) [@vijet](https://devforum.okta.com/u/vijet)\
**Post date:** [November 21, 2017, 9:22pm UTC](https://devforum.okta.com/t/custom-login-with-springboot-and-authorization-code-flow/787/2 "2017-11-21T21:22:56Z")

</div>

We have a sample repo which uses the okta sign-in widget to customize your login experience.  
It doesn’t use our spring-boot client library though.

You can take a look at the sample code here - [https://github.com/okta/samples-java-spring-mvc](https://github.com/okta/samples-java-spring-mvc)

We also have an example application that uses the spring-boot library with custom login page - [https://github.com/okta/okta-spring-boot/tree/master/examples/hosted-login-code-flow](https://github.com/okta/okta-spring-boot/tree/master/examples/hosted-login-code-flow)

@bdemers can help you with any questions you have. 🙂

---

<div class="post-metadata">

**Author:** ![bdemers](https://sea1.discourse-cdn.com/oktadev/user_avatar/devforum.okta.com/bdemers/32/23_2.png) [@bdemers](https://devforum.okta.com/u/bdemers)\
**Post date:** [November 22, 2017, 2:12am UTC](https://devforum.okta.com/t/custom-login-with-springboot-and-authorization-code-flow/787/3 "2017-11-22T02:12:56Z")

</div>

@josh.hardy.ufen for okta/samples-java-spring take a look at:  
[https://github.com/okta/samples-java-spring-mvc/tree/v2/custom-login](https://github.com/okta/samples-java-spring-mvc/tree/v2/custom-login)  
This code will be merged to master really soon, so if that branch no longer exists, it has already been merged and will be [https://github.com/okta/samples-java-spring-mvc/tree/master/custom-login](https://github.com/okta/samples-java-spring-mvc/tree/master/custom-login) (for future googlers)

Okta also supports a hosted custom login page, on some of the tiers.

---

<div class="post-metadata">

**Author:** ![josh.hardy.ufen](https://avatars.discourse-cdn.com/v4/letter/j/dc4da7/32.png) [@josh.hardy.ufen](https://devforum.okta.com/u/josh.hardy.ufen)\
**Post date:** [November 22, 2017, 11:31pm UTC](https://devforum.okta.com/t/custom-login-with-springboot-and-authorization-code-flow/787/4 "2017-11-22T23:31:32Z")

</div>

what tiers are these? I don’t see this called out in the pricing page.

---

<div class="post-metadata">

**Author:** ![josh.hardy.ufen](https://avatars.discourse-cdn.com/v4/letter/j/dc4da7/32.png) [@josh.hardy.ufen](https://devforum.okta.com/u/josh.hardy.ufen)\
**Post date:** [November 22, 2017, 11:32pm UTC](https://devforum.okta.com/t/custom-login-with-springboot-and-authorization-code-flow/787/5 "2017-11-22T23:32:26Z")

</div>

also, without customizing the login page, how does one have social login as part of the free tier?

---

<div class="post-metadata">

**Author:** ![shawn.recinto](https://sea1.discourse-cdn.com/oktadev/user_avatar/devforum.okta.com/shawn.recinto/32/38_2.png) [@shawn.recinto](https://devforum.okta.com/u/shawn.recinto)\
**Post date:** [November 27, 2017, 10:08pm UTC](https://devforum.okta.com/t/custom-login-with-springboot-and-authorization-code-flow/787/6 "2017-11-27T22:08:51Z")

</div>

Yep, I have an example in python/flask here in github… The documentation for configuring everything is a bit scant but you can take a look at the code while I update the docs to give a more full Okta walk through on setting up the example.

> **[srecinto/okta-oidc-python-flask](https://github.com/srecinto/okta-oidc-python-flask)**
>
> This is a simple application on using Okta's OIDC endpoints to access web properties - srecinto/okta-oidc-python-flask

---

<div class="post-metadata">

**Author:** ![shawn.recinto](https://sea1.discourse-cdn.com/oktadev/user_avatar/devforum.okta.com/shawn.recinto/32/38_2.png) [@shawn.recinto](https://devforum.okta.com/u/shawn.recinto)\
**Post date:** [November 27, 2017, 10:12pm UTC](https://devforum.okta.com/t/custom-login-with-springboot-and-authorization-code-flow/787/7 "2017-11-27T22:12:22Z")

</div>

Here is a link to the pricing for the developer licenses, reach out to the “contact us” option for more questions on pricing and additional tiers that may better fit your uses cases  
[https://developer.okta.com/pricing/](https://developer.okta.com/pricing/)

---

<div class="post-metadata">

**Author:** ![shawn.recinto](https://sea1.discourse-cdn.com/oktadev/user_avatar/devforum.okta.com/shawn.recinto/32/38_2.png) [@shawn.recinto](https://devforum.okta.com/u/shawn.recinto)\
**Post date:** [November 27, 2017, 10:15pm UTC](https://devforum.okta.com/t/custom-login-with-springboot-and-authorization-code-flow/787/8 "2017-11-27T22:15:09Z")

</div>

I should have just made one giant reply 😉  
For the Social login, that comes standard with the free tier. The Okta Sign On Widget supports social Auth out of the box but you can check out our reference docs here for Social Auth integration:  
[https://developer.okta.com/authentication-guide/social-login/](https://developer.okta.com/authentication-guide/social-login/)

---

<div class="post-metadata">

**Author:** ![josh.hardy.ufen](https://avatars.discourse-cdn.com/v4/letter/j/dc4da7/32.png) [@josh.hardy.ufen](https://devforum.okta.com/u/josh.hardy.ufen)\
**Post date:** [November 28, 2017, 12:49pm UTC](https://devforum.okta.com/t/custom-login-with-springboot-and-authorization-code-flow/787/9 "2017-11-28T12:49:28Z")

</div>

Ok. Thanks. If I understand you right, the free developer tier does allow for a custom login widget which is how we can use the social login experience such as Facebook Login.

It’s difficult to use just a single tutorial. It seems like they all have a piece of information that I need.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/oktadev/original/1X/589c4c5f80de422d01f47cee7185a7fb8227835c.png) [@system](https://devforum.okta.com/u/system)\
**Post date:** [January 12, 2024, 9:22pm UTC](https://devforum.okta.com/t/custom-login-with-springboot-and-authorization-code-flow/787/10 "2024-01-12T21:22:38Z")

</div>

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