A Quick Guide to React Login Options

A Quick Guide to React Login Options

This tutorial shows you how to add login options to a React app. Includes redirecting to log in, embedding a sign-in widget, and using plain ol’ JavaScript.

Jesse W

Hey! Not sure, if you’ll see this, but I’ve successfully implemented the “Create Your Own Login Form” component as a functional component in my app. Currently, I also now need to add Facebook as a login option too, and for now just added a button that takes you to the Facebook login page… however I have no idea if it’s working because the callback takes me to some crazy page. I see a couple other posts mention adding an IDP option in the login… any idea where I would add it in the CYLF option?

Thank you!!!

Matt Raible

If you want to add social login with Facebook via Okta, see our guide for Facebook. You will need to customize your hosted sign-in widget (or the one embedded within your app) to include settings for Facebook.

Refael dimri

Cab i use this to my website? Where all the users are stored?

Jesse W

Hey Matt,

I followed the guide, just posted a ticket. I don’t mind for now using a button that targets my authorization URL (users likely would rather see the FB login if they are using FB, seems more legit) but after a successful login through that, im redirected back without being authenticated. I do have a giant #id_token=giant_string but not sure what that does… any assistance is greatly appreciated!

Jesse W

i was able to add this pretty easily to my site, users are stored in your okta directory

Jesse W

nvm figured it out!