How it works
The modal has two states:- Warning — appears before the session expires, with two buttons:
- Continue sends a lightweight request to the server, refreshes the session, and dismisses the modal.
- Log Out redirects the user to the logout page.
- Expired — if the user does not act in time, the modal switches to an expired state with a single Reload button that refreshes the page so the user can log in again.
When the warning appears
The warning timing is derived from the session lifetime:| Session lifetime | Warning appears |
|---|---|
| 20 minutes or longer | 10 minutes before expiry |
| Less than 20 minutes | At the halfway point of the session |
| Less than 5 minutes | Not shown |
Configuring the session lifetime
The session lifetime is controlled by theSESSION_LIFETIME value in your .env file, expressed in
minutes. The default is 360 minutes (6 hours).
Relationship to automatic logout
This feature is separate from Curator’s automatic logout. Both can be active at the same time:- Automatic logout tracks user activity in the browser (mouse, keyboard, scrolling). It exists to log out users who have stepped away from their desk.
- Session expiration warning tracks the server-side session. It exists to warn users whose session is about to expire on the server even though they may still have the page open.