SMTP service is missing on windows 11

Anonymous
2024-05-23T05:52:41+00:00

Hello,

I am testing nodemailer on my node.js localbased server and I keep getting SMTP related errors. All ports giving the same errors:

[2024-05-23 05:42:40] DEBUG Sending mail using SMTP/6.9.13[client:6.9.13]

[2024-05-23 05:42:42] DEBUG [DPbtBTaxh6U] Resolved localhost as ::1 [cache miss]

[2024-05-23 05:42:42] ERROR [DPbtBTaxh6U] connect ECONNREFUSED ::1:587

[2024-05-23 05:42:42] DEBUG [DPbtBTaxh6U] Closing connection to the server using "destroy"

[2024-05-23 05:42:42] ERROR Send Error: connect ECONNREFUSED ::1:587

Error sending email: Error: connect ECONNREFUSED ::1:587

at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1602:16) { 

errno: -4078,

code: 'ESOCKET',

syscall: 'connect',

address: '::1',

port: 587,

command: 'CONN'

}

I tried to ping the smtp ports on localmachine and no of them (25, 2525, 587, 465) are working.
I have checked the services.msc and could not find Simple Mail Transfer Protocol (SMTP) service at all.

I have a feeling that because of this service is missing, i cant send emails with nodemailer.

I am using https://mailtrap.io/ and its provided instructions how to use smtp.

var transport = nodemailer.createTransport({ 2 host: "sandbox.smtp.mailtrap.io", 3 port: 2525, 4 auth: { 5 user: "838e9be05a94db", 6 pass: "********c98c" 7 } 8});

Their smtp server is working fine. Just mine localmachine servers arent pinging.

Please help to solve this.

Windows for business | Windows Server | Directory services | Other

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question. To protect privacy, user profiles for migrated questions are anonymized.

0 comments No comments
{count} vote
Accepted answer
  1. Anonymous
    2024-05-23T06:19:34+00:00

    Hi VrajaBihariDas,

    Thank you for posting in the Microsoft Community Forums.

    This is because Windows 11 no longer has a built-in SMTP service. But you can you can use an external SMTP service provider such as Gmail, Outlook, SendGrid, etc. to send emails. This is the simplest and recommended method as they provide reliable SMTP services and are easy to configure.

    Best regards

    Neuvi Jiang

    2 people found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful