refined-helicopter-87799
03/17/2025, 4:54 PMmethods:
password:
enabled: true
link:
enabled: true
code:
enabled: true
passwordless_enabled: true
how long the code which was sent via email stays active?brief-egg-61061
03/17/2025, 4:54 PMbrief-egg-61061
03/17/2025, 4:55 PMyaml selfservice: methods: code: enabled: true passwordless_enabled: true config: lifespan: 15m # Defines how long the code is valid for. Default: 1h
This would change the code's validity period to 15 minutes instead of the default 1 hour. The lifespan configuration applies to various flows that use the code method, including account recovery, verification, and passwordless login [Account recovery and password reset](https://www.ory.sh/docs/kratos/self-service/flows/account-recovery-password-reset#configuration).