How to extend session lifetime beyond 24 hours in Microsoft Entra External ID (CIAM) to prevent daily automatic logouts?

Vivaan Rajput 0 Reputation points
2025-10-21T11:42:55.8866667+00:00

Details:

I'm using Microsoft Entra External ID (ciamlogin.com) for customer authentication in my SPA application, and users are automatically logged out every 24 hours. I need to extend the session lifetime to keep users signed in for longer periods (weeks/months).

Current Configuration:

  • Tenant type: External ID (CIAM) with ciamlogin.com authority
  • Application type: Single Page Application (SPA) using MSAL.js v4.12.0
  • User flow: Sign-up/Sign-in policy
  • Scopes requested: openid, profile, offline_access
  • Cache location: localStorage
  • storeAuthStateInCookie: true

Issue:

  • Users are logged out automatically after ~24 hours
  • MSAL's acquireTokenSilent() returns InteractionRequiredAuthError after this period
  • localStorage contains valid refreshToken, but it appears to expire server-side after 24 hours

What I've tried:

  1. Verified offline_access scope is included in login request
  2. Confirmed MSAL tokens (access, ID, refresh) are persisted in localStorage
  3. Looked for Conditional Access session controls - these are unavailable (message: "This feature is unavailable or doesn't apply to the current tenant configuration")
  4. Checked user flow settings - no visible session lifetime or "Keep me signed in" (KMSI) configuration options
  5. Reviewed app manifest - no token lifetime properties exposed

Questions:

  1. How do I configure session/token lifetimes in Entra External ID (CIAM) to extend beyond 24 hours?
  2. Where is the "Keep me signed in" (KMSI) toggle located for External ID tenants?
  3. Are session controls configured at the user flow level, tenant level, or app registration level in External ID?
  4. If these settings are not exposed in the portal UI for External ID, is there a Microsoft Graph API or PowerShell method to configure longer refresh token lifetimes?Details: I'm using Microsoft Entra External ID (ciamlogin.com) for customer authentication in my SPA application, and users are automatically logged out every 24 hours. I need to extend the session lifetime to keep users signed in for longer periods (weeks/months). Current Configuration:
    • Tenant type: External ID (CIAM) with ciamlogin.com authority
    • Application type: Single Page Application (SPA) using MSAL.js v4.12.0
    • User flow: Sign-up/Sign-in policy
    • Scopes requested: openid, profile, offline_access
    • Cache location: localStorage
    • storeAuthStateInCookie: true
    Issue:
    • Users are logged out automatically after ~24 hours
    • MSAL's acquireTokenSilent() returns InteractionRequiredAuthError after this period
    • localStorage contains valid refreshToken, but it appears to expire server-side after 24 hours
    What I've tried:
    1. Verified offline_access scope is included in login request
    2. Confirmed MSAL tokens (access, ID, refresh) are persisted in localStorage
    3. Looked for Conditional Access session controls - these are unavailable (message: "This feature is unavailable or doesn't apply to the current tenant configuration")
    4. Checked user flow settings - no visible session lifetime or "Keep me signed in" (KMSI) configuration options
    5. Reviewed app manifest - no token lifetime properties exposed
    Questions:
    1. How do I configure session/token lifetimes in Entra External ID (CIAM) to extend beyond 24 hours?
    2. Where is the "Keep me signed in" (KMSI) toggle located for External ID tenants?
    3. Are session controls configured at the user flow level, tenant level, or app registration level in External ID?
    4. If these settings are not exposed in the portal UI for External ID, is there a Microsoft Graph API or PowerShell method to configure longer refresh token lifetimes?
Microsoft Security | Microsoft Entra | Microsoft Entra External ID

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.