When using programmatic mailbox access tools such as Exchange Web Services (EWS) or Microsoft Graph API on on-premises Exchange Server 2016/2019/SE or Exchange Online, the error “The SMTP address has no mailbox associated” may occur. This usually means that the specified SMTP address cannot be linked to an active mailbox.
Although the examples in our article focus on Exchange Web Services (EWS), the same mailbox config issues frequently affect Microsoft Graph API mailbox operations as well.
In my case, this error occurred when I tried to send an email via EWS using a PowerShell script on behalf of an Exchange Server mailbox:
The SMTP address has no mailbox associated with it.
[ErrorNonExistentMailbox]
Or
[ErrorNonPrimarySmtpAddress]

Common Causes of “SMTP Address Has No Mailbox Associated”
| Cause | Description |
|---|---|
| Mailbox doesnโt exist | SMTP address cannot be resolved to a mailbox |
| Using proxy address | Secondary SMTP address used instead of Primary SMTP |
| Mail-enabled user | Recipient exists but is not a mailbox |
| Shared mailbox authentication | Application attempts to authenticate directly to a shared mailbox |
| Disconnected mailbox | Mailbox exists but is disconnected |
| Account disabled or locked | Authentication cannot complete |
| Missing Exchange Online license | Mailbox has not been provisioned |
| Mailbox provisioning delay | Mailbox creation has not completed after license assignment |
| Hidden mailbox | Mailbox unavailable for some operations |
| Hybrid mailbox location mismatch | Application connects to the wrong Exchange environment |
Fixing SMTP address has no mailbox associated with it
This issue may occur when using third-party tools to connect to an Exchange mailbox via EWS, such as migration or backup tools (like Veeam), Python or PowerShell scripts, or other EWS-based apps.
ErrorNonExistentMailbox vs ErrorNonPrimarySmtpAddress
ErrorNonExistentMailbox
This issue occurs when Exchange cannot find any mailbox matching the supplied SMTP address. The common causes are:
- mailbox deleted
- mailbox never existed
- wrong SMTP address
- disconnected mailbox
ErrorNonPrimarySmtpAddress
This error occurs when the mailbox exists but the supplied SMTP address is not configured as the primary SMTP address. For example:
Get-Mailbox user |
Select PrimarySmtpAddress,EmailAddresses
According to the error message, the specified SMTP email address cannot be resolved to a mailbox. Ensure that the script contains an existing source or target email address and that this matches the user’s primary SMTP address.
- If you specified a username in the format contoso\user for connection, replace it with the UPN format user@contoso.com.
Ensure that the specified user account (UPN address) exists within the Exchange organization (tenant).
Exchange Online:Get-EXOMailbox -Filter {EmailAddresses -eq 'cyril@theitbros.com'}On-prem Exchange Server:
Get-Mailbox -Identity user@contoso.com

- If the mailbox for the specified SMTP address cannot be found, it may be configured in the settings of a mail-enabled account. Exchange Web Services authentication cannot be performed using mail-enabled accounts (mail-enabled users):
Get-Recipient -Filter "EmailAddresses -eq 'smtp:cyril@theitbros.com'"
-
Now you need to check if the mailbox is a shared mailbox. Run the command:
Get-Mailbox cyril@theitbros.com | Select-Object RecipientTypeDetails
In case RecipientTypeDetails is SharedMailbox, you need to authenticate with a user account that has Full Access permissions to the shared mailbox (instead of using the shared mailbox directly).
- The account must not be locked:
Get-ADUser -Identity username -Properties LockedOut | Select-Object SamAccountName, LockedOut Get-MgUser -UserId cyril@theitbros.com | Select-Object UserPrincipalName, AccountEnabled
- Check that the specified SMTP address is not a disconnected mailbox:
Get-MailboxStatistics -Identity cyril@theitbros.com | Select-Object DisplayName, DisconnectReason
- Use Outlook Web App (OWA) to verify that you can authenticate with this account.
- The specified UPN address must be the primary SMTP address of the mailbox, and not an additional (proxy address) in the EmailAddresses attribute:
Get-Mailbox cyril@theitbros.com | Select-Object DisplayName, PrimarySmtpAddress, EmailAddresses

- If you are using an Exchange Online mailbox, ensure that an Exchange license has been assigned to it:
Get-MgUser -UserId cyril@theitbros.com -Property AssignedLicenses | Select-Object DisplayName, AssignedLicenses - Ensure that the mailbox is not hidden from the Global Address List (GAL):
Get-Mailbox -Identity cyril@theitbros.com | Select-Object DisplayName, HiddenFromAddressListsEnabled

If hidden, unhide it:
Set-Mailbox -Identity cyril@theitbros.com -HiddenFromAddressListsEnabled $false
Does This Error Also Apply to Microsoft Graph API?
Note that the same underlying mailbox-related problems can also trigger mailbox resolution errors when using Microsoft Graph API. Unlike Exchange Web Services (EWS), instead of ErrorNonExistentMailbox and ErrorNonPrimarySmtpAddress, Microsoft Graph typically returns such errors:
MailboxNotEnabledForRESTAPI
or
ResourceNotFound
However, you should keep in mind that the root causes for these errors are usually the same:
- the user doesn’t have an Exchange mailbox;
- the mailbox hasn’t been provisioned yet;
- an incorrect SMTP address or UPN is used;
- the account is unlicensed in Exchange Online;
- the mailbox is soft-deleted or disconnected.
In order to check mailbox availability for a Graph API user, run the command:
Get-EXOMailbox -Identity cyril@theitbros.com
In case the mailbox cannot be found, Microsoft Graph won’t be able to access mailbox resources such as:
- /messages
- /mailFolders
- /sendMail
- /events
In Hybrid Exchange environments, you need to ensure the mailbox exists in the Exchange environment your app is connecting to. Use the commands:
Get-EXOMailbox cyril@theitbros.com
Get-Mailbox cyril@theitbros.com
In case the mailbox is hosted in Exchange Online but the app connects to on-premises Exchange (or vice versa), you may face mailbox resolution errors.
Also keep in mind that in Hybrid Exchange deployments, migrated mailboxes are often represented as RemoteMailbox objects in on-premises AD:
Get-RemoteMailbox cyril@theitbros.com Reviewing these factors will help you identify the cause of mailbox resolution errors returned by EWS, Microsoft Graph API, and other Exchange-integrated apps.
What does โSMTP address has no mailbox associatedโ mean?
This error occurs in Microsoft Exchange Server or Exchange Online when a specified SMTP address cannot be mapped to an active mailbox. It is commonly triggered when using EWS or Microsoft Graph API for mailbox operations.
When does this error usually appear?
It typically occurs during programmatic mailbox access, for example:
- Exchange Web Services (EWS)
- Microsoft Graph API
- PowerShell scripts
- Backup or migration tools (e.g., Veeam)
What should I check first when troubleshooting?
Start with:
- Does the mailbox exist?
- Is the SMTP address primary?
- Is the account licensed and enabled?
- Is the mailbox in the correct environment (hybrid)?
- Is it shared or mail-enabled instead of a mailbox?
Does Exchange Online license affect this error?
Yes. Without a valid Exchange license, the mailbox is not provisioned and cannot be accessed.

