User sessions are cleared when a user tries to log in, and sessions are cleared every 24 hours from the sessions database table. Configure session lengths by going to System Console > Environment > Session Lengths, or by editing the config.json
file as described in the following tables. Changes to configuration settings in this section require a server restart before taking effect.
Extend session length with activity
Available in legacy Enterprise Edition E10/E20
Improves the user experience by extending sessions and keeping users logged in if they are active in their Mattermost apps.
|
|
Session length for AD/LDAP and email
Available in legacy Enterprise Edition E10/E20
Set the number of hours counted from the last time a user entered their credentials into the web app or the desktop app to the expiry of the user’s session on email and AD/LDAP authentication. Numerical input in hours. Default is 720 hours. |
|
Note: After changing this setting, the new session length takes effect after the next time the user enters their credentials. |
Session length for mobile
Available in legacy Enterprise Edition E10/E20
Set the number of hours counted from the last time a user entered their credential into the mobile app to the expiry of the user’s session. Numerical input in hours. Default is 720 hours. |
|
Note: After changing this setting, the new session length takes effect after the next time the user enters their credentials. |
Session length for SSO
Available in legacy Enterprise Edition E10/E20
Set the number of hours from the last time a user entered their SSO credentials to the expiry of the user’s session. This setting defines the session length for SSO authentication, such as SAML, GitLab, and OAuth 2.0. Numerical input in hours. Default is 720 hours. Numbers as decimals are also valid values for this configuration setting. |
|
Notes:
|
Session cache
Available in legacy Enterprise Edition E10/E20
Set the number of minutes to cache a session in memory. Numerical input in minutes. Default is 10 minutes. |
|
Session idle timeout
Available in legacy Enterprise Edition E10/E20
The number of minutes from the last time a user was active on the system to the expiry of the user’s session. Once expired, the user will need to log in to continue. Numerical input in minutes. Default is 43200 (30 days). Minimum value is 5 minutes, and a value of 0 sets the time as unlimited. |
|
Notes:
|