# Self-hosted Instance Cannot Send E-mails

**URL:** <https://forums.rocket.chat/t/self-hosted-instance-cannot-send-e-mails/22592>\
**Category:** Community Support\
**Created:** [November 5, 2025, 9:52pm UTC](https://forums.rocket.chat/t/self-hosted-instance-cannot-send-e-mails/22592 "2025-11-05T21:52:17Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![yann-gael](https://avatars.discourse-cdn.com/v4/letter/y/dbc845/32.png) [@yann-gael](https://forums.rocket.chat/u/yann-gael)\
**Post date:** [November 5, 2025, 9:52pm UTC](https://forums.rocket.chat/t/self-hosted-instance-cannot-send-e-mails/22592/1 "2025-11-05T21:52:17Z")

</div>

### Description

Hi!

My instance cannot send e-mails using Gmail. The logs show “Error: Connection timeout”. I can send e-mails manually though.

From my server, I can connect manually to [smtp.gmail.com](http://smtp.gmail.com) using `openssl s_client -connect ``smtp.gmail.com:465`` -crlf` and send a few emails successfully.

From my instance, using the same Google server, the same credentials, I cannot send e-mails. I configured my instance to show errors and information in the logs. Using `journalctl -u snap.rocketchat-server.rocketchat-server -f`, I see

```auto
Nov 05 21:12:09 PtidejPortal-2025-2029 rocketchat-server.rocketchat-server[77253]: {"level":35,"time":"2025-11-05T21:12:09.293Z","pid":77253,"hostname":"PtidejPortal-2025-2029","name":"Meteor","method":"sendSMTPTestEmail","userId":"gPwyT4oyCrKySThRa","remoteIP":"132.205.229.40","instanceId":"33c55734-f859-4a0f-8640-d0ed20522b43"}
Nov 05 21:12:09 PtidejPortal-2025-2029 rocketchat-server.rocketchat-server[77253]: {"level":35,"time":"2025-11-05T21:12:09.304Z","pid":77253,"hostname":"PtidejPortal-2025-2029","name":"API","method":"POST","url":"http://localhost/api/v1/method.call/sendSMTPTestEmail","userId":"gPwyT4oyCrKySThRa","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/142.0.0.0 Safari/537.36","length":"96","host":"chat.ptidej.net","referer":"https://chat.ptidej.net/admin/settings/Email","remoteIP":"132.205.229.40","status":200,"responseTime":21}
Nov 05 21:12:19 PtidejPortal-2025-2029 rocketchat-server.rocketchat-server[77253]: Error: Connection timeout
Nov 05 21:12:19 PtidejPortal-2025-2029 rocketchat-server.rocketchat-server[77253]: at SMTPConnection._formatError (/snap/rocketchat-server/1738/programs/server/npm/node_modules/meteor/email/node_modules/nodemailer/lib/smtp-connection/index.js:790:19)
Nov 05 21:12:19 PtidejPortal-2025-2029 rocketchat-server.rocketchat-server[77253]: at SMTPConnection._onError (/snap/rocketchat-server/1738/programs/server/npm/node_modules/meteor/email/node_modules/nodemailer/lib/smtp-connection/index.js:776:20)
Nov 05 21:12:19 PtidejPortal-2025-2029 rocketchat-server.rocketchat-server[77253]: at Timeout.<anonymous> (/snap/rocketchat-server/1738/programs/server/npm/node_modules/meteor/email/node_modules/nodemailer/lib/smtp-connection/index.js:235:22)
Nov 05 21:12:19 PtidejPortal-2025-2029 rocketchat-server.rocketchat-server[77253]: at listOnTimeout (node:internal/timers:594:17)
Nov 05 21:12:19 PtidejPortal-2025-2029 rocketchat-server.rocketchat-server[77253]: at processTimers (node:internal/timers:529:7) {
Nov 05 21:12:19 PtidejPortal-2025-2029 rocketchat-server.rocketchat-server[77253]: code: 'ETIMEDOUT',
Nov 05 21:12:19 PtidejPortal-2025-2029 rocketchat-server.rocketchat-server[77253]: command: 'CONN'
Nov 05 21:12:19 PtidejPortal-2025-2029 rocketchat-server.rocketchat-server[77253]: }

```

I configured Rocket.Chat with:

- Protocol: smtp
- Host: [smtp.gmail.com](http://smtp.gmail.com)
- Port: 465
- IgnoreTLS: off
- Pool: on
- Username: \<my Gmail username with @gmail.com\>
- Password: \<the 16 chars of an App password\>
- From Email:

### Server Setup Information

- Version of Rocket.Chat Server: 7.12.0
- Operating System: Ubuntu v22.04
- Deployment Method: snap
- Number of Running Instances: 1
- DB Replicaset Oplog: Enabled
- NodeJS Version: 22.13.1
- MongoDB Version: 6.0.19
- Proxy: nginx
- Firewalls involved: ufw

### Any additional Information

---

<div class="post-metadata">

**Author:** ![reetp](https://sea1.discourse-cdn.com/flex021/user_avatar/forums.rocket.chat/reetp/32/5546_2.png) [@reetp](https://forums.rocket.chat/u/reetp)\
**Post date:** [November 6, 2025, 8:58am UTC](https://forums.rocket.chat/t/self-hosted-instance-cannot-send-e-mails/22592/2 "2025-11-06T08:58:00Z")

</div>

Real answer is don’t use Google 🙂

They don’t want you too anyway.

This may help you, but eventually they’ll probably block most “app” access without 2FA.

> [@Google SMTP for the email](https://forums.rocket.chat/t/google-smtp-for-the-email/11075/9):
>
> Hi all. 8/21/2024 and I’m successfully using a secure (smtps) variation of Vladislav’s solution above. To reiterate, you need to enable 2FA on the Google account in order to create an app password for the RocketChat mailer, which you’ll use as the password, below: Protocol: smtps Host: [smtp.gmail.com](http://smtp.gmail.com) Port: 465 IgnoreTLS: off (forced off by choice of smtps protocol) Pool: off Username: [Username@GoogleWorkspaceDomain.com](mailto:Username@GoogleWorkspaceDomain.com) (your google email address) Password: \*\*\*\* \*\*\*\* \*\*\*\* \*\*\*\* (Google App …

---

<div class="post-metadata">

**Author:** ![yann-gael](https://avatars.discourse-cdn.com/v4/letter/y/dbc845/32.png) [@yann-gael](https://forums.rocket.chat/u/yann-gael)\
**Post date:** [November 6, 2025, 10:27pm UTC](https://forums.rocket.chat/t/self-hosted-instance-cannot-send-e-mails/22592/3 "2025-11-06T22:27:07Z")

</div>

Hi @reetp and thank you for your answer!

I was trying to use the exact same configuration as I am using for Ghost, but your answer led me to try using `smtps` instead of `smtp` and it now works!

For others who’d like to use Gmail anyway, here’s my configuration that works:

- Protocol: `smtps` (yes, the secure one)
- Host: `smtp.gmail.com`
- Port: 465
- IgnoreTLS: doesn’t matter, it’s disabled by the choice of `smtps` above
- Pool: off
- Username: `<username>@gmail.com`
- Password: one App password
- From Email: `<username>@gmail.com`

Cheers!  
Yann

---

<div class="post-metadata">

**Author:** ![reetp](https://sea1.discourse-cdn.com/flex021/user_avatar/forums.rocket.chat/reetp/32/5546_2.png) [@reetp](https://forums.rocket.chat/u/reetp)\
**Post date:** [November 6, 2025, 10:46pm UTC](https://forums.rocket.chat/t/self-hosted-instance-cannot-send-e-mails/22592/4 "2025-11-06T22:46:31Z")

</div>

No need to `@`

Yup in 2025 use `s` everywhere.
