Nodemailer: Greeting never received Email / SMTP Origin: Network Last updated 4 Nov 2026

Nodemailer: Error: Greeting never received (code: 'ETIMEDOUT', command: 'CONN')

The TCP connection was made but the server never sent its SMTP 220 banner — usually a TLS mode mismatch or a firewall/proxy swallowing the traffic.

Exact message you may see Greeting never receivedError: Greeting never receivednodemailer Greeting never received ETIMEDOUTcode: 'ETIMEDOUT', command: 'CONN' greetingSMTP greeting timeout
Seen on: SMTP Node.js

Meaning

The classic cause is secure: true on port 587, or secure: false on 465: the client waits for plain text while the server speaks TLS (or the reverse). Fix the pair: 465 with secure: true, 587 with secure: false (STARTTLS). Slow servers may need a larger greetingTimeout.

Common causes

  • secure flag does not match the port
  • Firewall or antivirus content-scanning SMTP
  • Proxy/VPN interfering
  • Very slow server or DNS
  • Using port 25 with TLS on

⚡ Quick fix

  1. 465 → secure: true; 587 → secure: false with requireTLS: true
  2. Increase greetingTimeout to 30000
  3. Try from another network to rule out a firewall

Detailed fix by platform

Linux

  1. nc smtp.example.com 587 should immediately print a line starting with 220; silence means the mode is wrong or traffic is blocked

How to diagnose

  1. Pair — secure matches port?
  2. Banner — 220 shown by nc?
  3. Network — Proxy/AV?

🔧 Still not fixed?

Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:

Where this error sits

Origin: Network. Errors that are often confused with or caused by this one (click to open):

421 4.7.0 Try again later (rate limited) — SMTP: 421 4.7.0 Our system has detected an unusual rate of unsolicited mail originating from your IP address. Mail sent from your IP address has been temporarily rate limited (Email / SMTP)421 4.7.0 Try again l…450 4.7.1 Greylisted, please try again later — SMTP: 450 4.7.1 <user@example.com>: Recipient address rejected: Greylisted, see http://postgrey.schweikert.ch/help/example.com.html (Email / SMTP)450 4.7.1 Greylisted,…530 5.7.0 Authentication Required — SMTP: 530 5.7.0 Must issue a STARTTLS command first / 530 5.7.1 Authentication required (Email / SMTP)530 5.7.0 Authenticat…Nodemailer: EAUTH Invalid login — Nodemailer: Error: Invalid login: 535-5.7.8 Username and Password not accepted (code: 'EAUTH', responseCode: 535) (Email / SMTP)Nodemailer: EAUTH Inv…Nodemailer: ETIMEDOUT / ECONNECTION — Nodemailer: Error: connect ETIMEDOUT 142.250.27.108:465 (code: 'ETIMEDOUT', command: 'CONN') (Email / SMTP)Nodemailer: ETIMEDOUT…self-signed certificate (SMTP TLS) — Nodemailer: Error: self signed certificate in certificate chain (code: 'ESOCKET') / unable to verify the first certificate (Email / SMTP)self-signed certifica…SSL: WRONG_VERSION_NUMBER (SMTP port) — SMTP: [SSL: WRONG_VERSION_NUMBER] wrong version number — SMTP over SSL on a STARTTLS port (Email / SMTP)SSL: WRONG_VERSION_NU…Nodemaile…

Explore the map of this error Full error map →

🧠 Still stuck? Analyze your error

Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.

💬 What worked for others

No tips yet — did something else fix this for you?

Share what worked for you

Tips are checked by an editor before they appear. Links are removed.