Relevant Flask configuration values#

The following configuration values are from Flask itself that are relate to the Flask session cookie set on the browser. Flask-Session loads these values from your Flask application config, so you should configure your app first before you pass it to Flask-Session.

These values cannot be modified after the init_app was applied so make sure to not modify them at runtime.

SESSION_COOKIE_NAME

SESSION_COOKIE_DOMAIN

SESSION_COOKIE_PATH

SESSION_COOKIE_HTTPONLY

SESSION_COOKIE_SECURE

SESSION_COOKIE_SAMESITE

SESSION_REFRESH_EACH_REQUEST

PERMANENT_SESSION_LIFETIME

Note

PERMANENT_SESSION_LIFETIME is also used to set the expiration time of the session data on the server side, regardless of SESSION_PERMANENT.