Multi-Factor Authentication (MFA)

Available on the following plans

FreeBasicPremiumUltimateEnterprise

About Multi-Factor Authentication (MFA)

Multi-Factor Authentication (MFA) adds additional security to your application by requiring that your users provide 2 identity factors when signing into your application. MFA is sometimes also called Two-Factor Authentication (2FA).

The following table lists the factors available for your application. On Userfront, any factor can be a first factor or a second factor, and by default a user's first and second factors must use a different channel from one another.

Strategy
Channel
Password
Email (for password reset)
Passwordless / email login link
Email
Single Sign-On (SSO): Google, Apple, Azure AD / Entra ID, GitHub, etc.
Email
Email verification code
Email
SMS verification code
SMS
Time-based One-Time Password (TOTP)
Authenticator app

MFA Requirements

You can configure your application to handle any of the following scenarios:

Configuration
Description
MFA disabled
Don't allow MFA for any users.
MFA optional
Allow MFA for users who want to configure it, but do not require MFA for all users.
MFA required for some users
Require MFA for specific users, or for users with access to certain organizations within your application.
MFA required for all users
Require MFA for all users of your application.

    MFA Handling

    Userfront automatically handles MFA enforcement on a per-user level. Users who do not have MFA required can use the same login flows and API endpoints as users who do require MFA.

    Userfront’s API endpoints handle both single- and multi-factor authentication flows.

    Users who do not have MFA enabled receive their JWT access token upon submitting the first factor:

    Diagram of login without Multi-Factor Authentication (MFA)

    Users who have MFA enabled receive their JWT access token upon submitting the first factor:

    Diagram of login with Multi-Factor Authentication (MFA)