[Vaultwarden] SMTP issues

What app is this about, and its version: Vaultwarden, 1.37.0~ynh1
What YunoHost version are you running: 12.1.40.1
What type of hardware are you using: VPS bought online

Describe your issue

Vaultwarden displays information about SMTP issues when I try to add someone to an org and it tries to send an email. The SMTP section of the .env file:

#SMTP_HOST=apps.kavela.ch
SMTP_HOST=127.0.0.1
SMTP_FROM=vaultwarden@apps.kavela.ch
SMTP_FROM_NAME=Vaultwarden
SMTP_USERNAME=vaultwarden
SMTP_PASSWORD=redacted

as you can see above the host was different, but I tried to use the tip from here, to no avail :confused:

Share relevant logs or error messages

/var/log/vaultwarden/vaultwarden.log shows:

[2026-07-28 22:27:36.051][vaultwarden::mail][ERROR] SMTP 5xx error: permanent error (535): 5.7.8 Error: authentication failed: (reason unavailable) - Authentication credentials invalid
[2026-07-28 22:27:36.051][vaultwarden::mail][ERROR] SMTP 5xx error: permanent error (535): 5.7.8 Error: authentication failed: (reason unavailable) - Authentication credentials invalid
[2026-07-28 22:27:36.054][vaultwarden::api::core::organizations][ERROR] Error sending invite: SMTP 5xx error: permanent error (535): 5.7.8 Error: authentication failed: (reason unavailable) - Authentication credentials invalid
[2026-07-28 22:27:36.054][vaultwarden::api::core::organizations][ERROR] Error sending invite: SMTP 5xx error: permanent error (535): 5.7.8 Error: authentication failed: (reason unavailable) - Authentication credentials invalid

why have you changed SMTP_HOST? I think domain name was OK here.

To add some context apps are given SMTP credentials only valid if the authentication attempts comes from some realm and I think host name where the app is installed is the right one.

@JfmbLinux hello, thanks for your post, but could you point to the specific part of these that might help me? I use the default yunohost configuration (well, besides the SMTP_HOST change), I don’t use any of the big providers.

@orhtej2 I tried to follow the tip from this thread but it didn’t work :confused: I went back to the default configuration but it did not fix the issue (the domain matches the one that vaultwarden runs on).

Try changing SMTP_PORT to 587
But you have to reset the host to the domain of vaultwarden.

Did you change the password? If not, does it contain special characters?

Changing the port did not help :confused: I did not change the password and it does only contain letters and numbers.

Is it the same error message?

Try setting smtp host as the default domain of your server