How to properly configure SQL Database Mail to send through an Office 365 SMTP server without using an on-prem SMTP server? [closed]

dba.stackexchange https://dba.stackexchange.com/questions/251814

Question

We used to use SQL Database Mail through an on-prem SMTP server, but have since transitioned to Office 365.

I created a new profile for O365 and tried configuring a new account in that profile like this: SQL Database Mail Account

I've also tried smtp.office365.com as the "Server name".

When I try sending a test email, I never receive it. The error message I get in the Database Mail Log is below: SQL Database Mail - Mail Log Errors

Was it helpful?

Solution

It turned out we were using the wrong "Server name" and "Port" all along. Inputting the correct server and port fixed our issue. (It really is that simple to setup database mail through O365 :)

Licensed under: CC-BY-SA with attribution
Not affiliated with dba.stackexchange
scroll top