Skip to content
  • There are no suggestions because the search field is empty.

Error when sending emails via SMTP in Microsoft 365

"The mail send has failed. Error 535 5.7.139 Authentication unsuccessful, SmtpClientAuthentication is disabled for the Tenant"

This error occurs when SMTP authentication is disabled in your Microsoft 365 tenant or mailbox settings.

To prevent the error, ensure all required SMTP settings are enabled before testing the connection. You have two options for how to set up SMTP:

Still getting the error after trying both options? You can enable SMTP authentication for a specific mailbox. This is often required even if OAuth is on.

Option 1: If using basic authentication, disable security defaults

If your organization uses basic authentication for SMTP (for example, older applications or devices), you need to disable Microsoft’s Security Defaults in Azure AD.

  1. Go to the Microsoft Entra Admin Center (previously Azure Active Directory).
  2. Select Azure Active Directory.
  3. From the left-hand menu, select Properties.
  4. Scroll down to the Access management for Azure resources section.
  5. Click Manage security defaults.
  6. Set the toggle to Yes to disable security defaults.
  7. Click Save.

Option 2: Enable SMTP authentication for specific protocols

If you prefer to keep security defaults on, you can instead enable SMTP AUTH for specific protocols using the Microsoft 365 Admin Center. The steps differ depending on whether you're using the old Admin Center user interface, or the new interface.

New Admin Center interface

  1. Go to the Microsoft 365 Admin Center.
  2. From the menus on the left, click Setup.
  3. In the search bar at the top, search for "modern authentication". The Modern authentication side panel opens.
  4. Ensure the Authenticated SMTP checkbox is not selected (disabled for basic authentication).

Old Admin Center interface

  1. Go to the Microsoft 365 Admin Center.
  2. Go to Settings > Org Settings.
  3. On the Services tab, click Modern authentication.
  4. In the Modern authentication side panel, ensure Authenticated SMTP is unchecked.

If other options don't work, enable SMTP authentication for a specific mailbox

If you still experience the error after completing the above steps, check that SMTP AUTH is enabled for the specific mailbox being used.

  1. Log in to the Microsoft 365 Admin Center.
  2. Go to Users > Active users.
  3. Select the mailbox used for sending emails.
  4. In the panel on the right, go to the Mail tab.
  5. Scroll to Authenticated SMTP and ensure the checkbox is selected.
    If it’s already selected, try deselecting it then selecting it again.
  6. Click Save changes.