With Nhost it's easy to sign in users with external OAuth providers. OAuth providers are configured in the Nhost console at Settings -> Sign-in methods.
You must first set the auth redirect URLs to start using a OAuth provider. The redirect URL specifies where your users should return to once the signup/signin has been completed.
If you develop locally, set the Redirect URLs to your local web app. Ex http://localhost:3000.
The flow for both signup and signin is the same. Simply link to https://backend-REPLACE.nhost.app/auth/providers/[provider]
in your signup/signin page.
[provider]
can be one ofgithub
,