How to enable JWT SSO

Enabling JWT SSO

When to use JWT SSO

OAuth2 is the recommended authentication method. However, JWT SSO is your best option if:

  • Your website or product does not support OAuth2
  • You plan to embed Bettermode in your product, marketing website, or mobile app using iFrame or WebView

JWT SSO requires only a few lines of code to implement.

How JWT SSO works

JWT SSO uses a JSON Web Token (JWT) signed with your private key to authenticate users. You sign the token with the user's information and pass it as a token parameter in the query string to Bettermode.

Enable JWT SSO

  1. Log in with your admin account.
  2. Click your profile picture in the top-right corner.
  3. Go to Administration > Settings > Authentication.
  4. Enable the toggle for JWT SSO.

Configure JWT SSO settings

  1. Click the Settings button.
  2. Configure the following fields on the next screen:
    • Authorization URL: Redirect users to this URL when they click the login button in Bettermode.
    • Logout URL: Redirect users to this URL when they click the logout button in Bettermode so they can log out from your main website or app.
    • Sign-up URL: Redirect users to this URL when they click the sign-up button in Bettermode.
    • Settings URL: Redirect users to this URL when they want to update their profile information (such as their name) in Bettermode.
    • Login Button Text: Enter the text you want to display on the SSO login button in Bettermode.

Complete JWT activation

Follow the steps in the Bettermode Developers Guide for JWT SSO to finish setting up JWT authentication.

Related topics

Contact Us

Do you still need help? Learn how to get in touch with the Bettermode Team.