Once activated, the default validity period for a web app session is 14 days. The duration of validity of a session is automatically restarted though, each time the web app user is active.
This duration can be modified for the workspace in Backstage.
To do so, go to Settings > General > Web app settings > select Enable WebApp-specific settings, then enter the desired duration of validity in seconds.
For mobile app, users are not logged out as there is no validity period.