Session-Based MFA requires users to complete an MFA challenge on every login.
You can configure session-based MFA in the Dynamic developer console, by toggling on the “Session-based MFA” option.
You can also choose to make it mandatory or not, by toggling the “Require at onboarding” option.
Required vs Optional
-
Required
If you make MFA required on onboarding, the user must have completed an MFA challenge on every login after this option is enabled.
You, as a developer, will be responsible for checking if the user is missing MFA authentication and prompting them to complete an MFA challenge if required.
-
Optional
If you don’t have MFA required on onboarding, the user will only be required to complete an MFA challenge on login if they have an MFA method registered.
You, as a developer, will be responsible for checking if the user is missing MFA authentication and prompting them to complete an MFA challenge if required.
Checking if a user is missing session-based MFA authentication
isUserMissingMfaAuth is synchronous, so call it during render and read useUser() so the gate re-evaluates when user state changes (e.g. after the MFA challenge is completed). useGetMfaMethods loads the registered methods:
Last modified on September 21, 2026