Published by https://wpmailsmtp.com/docs/how-to-set-up-the-outlook-mailer-in-wp-mail-smtp/?utm_source=WordPress&utm_medium=plugin-settings&utm_campaign=plugin&utm_locale=en_us&utm_content=Microsoft%20365%20%2F%20Outlook%20documentation
Thanks!! Education is key.
To get started, you’ll first need to install and activate the WP Mail SMTP plugin.
Once you’ve installed and activated the plugin, go to WP Mail SMTP » Settings. Under the General tab, you’ll see mailer configuration settings.

We’ll cover how to complete these settings in the next sections.
Mailer
Go ahead and skip the From Email and From Name settings for now. We’ll cover these in a later step.
You’ll first want to scroll to the Mailer section. From here, select the 365 / Outlook option.

Now that you’ve chosen the Microsoft 365 / Outlook.com mailer, you should see a new section titled 365 / Outlook.

There are two ways to configure the Outlook mailer: Using the One-Click Setup or manually creating and registering an app in Microsoft’s Azure portal.
If you prefer a straightforward approach, proceed to the activating One-Click Setup section of this guide. This method doesn’t require you to go through the tedious steps of registering an app.
However, if you’d rather generate the app ID and app password manually, you’ll need to use your Microsoft account to create a web application. To continue with this method, jump to the creating a web app section of this guide.
Activating One-Click Setup
For an easier and quicker email setup, we recommend using the One-Click Setup feature. It lets you connect your site to the Outlook mailer with a few clicks.
After selecting 365 / Outlook as your mailer in the WP Mail SMTP settings, you will find the option to activate the One-Click Setup. Simply switch this toggle to the ON position to begin the simplified setup process.

For more detailed information on the One-Click Setup process, be sure to check out our guide on configuring the Outlook mailer using the One-Click Setup feature.
Note: The One-Click Setup feature requires a Pro license or higher.
If you prefer to continue with the traditional approach or require a custom setup, please proceed with the rest of the steps outlined below.
To generate the information needed for this section, you’ll need to set up a web application in your Microsoft Azure account. This process doesn’t require any coding, and we’ll show you exactly what to do in the next step.
Be sure to keep these WP Mail SMTP settings open in a separate tab or window, as you’ll come back to them soon.
Configuring a Microsoft Azure Account
In order to move forward with the setup process, you’ll need to have a Microsoft Azure account.
Since you most likely already have a Microsoft email account (through Hotmail, Live, Outlook, Microsoft 365, etc), you can simply log into Microsoft Azure with your existing account credentials.
If you need to create a new account, click this link to sign up for a free Microsoft Azure account.
Note: The email you use for your Azure account must be a Microsoft-based email address with permission to send emails.
Next, you’ll need to open the Azure Portal if you’re not automatically redirected.
Create an Application ID
Once the Azure Portal is open, type App registrations in the search bar at the top of the page.

Next, you’ll see a dropdown menu with a list of services. Go ahead and click on App registrations.

At the top of the App Registrations page, you’ll need to select the + New registration option.

In the app registration form, here are the details you’ll need to fill out:
- Name: This is only for your personal organization, so we recommend naming it something like “WP Mail SMTP: yourdomain.com”.
- Supported account types: Select Accounts in any organizational directory and personal Microsoft accounts.

Note: For some Microsoft account types, you may only see the Accounts in any organizational directory (Any Azure AD – Multitenant) option. Go ahead and select this option if the Accounts in any organizational directory and personal Microsoft accounts option doesn’t appear for your account type.
- Redirect URI: For the first dropdown, leave this set to Web. Then for the second field, you’ll need to copy this value from your WP Mail SMTP settings (see below).
In order to find the Redirect URI, you’ll need to switch back to the tab or window where you left your site’s WP Mail SMTP settings open. Under the Outlook / 365 section, you’ll see a field named Redirect URI.

You’ll need to copy this value and then paste it into your Microsoft Azure app registration form. Be sure to still keep both windows/tabs open in your browser, as we’ll continue to switch between the two.

When you’re ready, click the Register button to proceed.

Note: After you’ve registered your application, be sure to double-check your Supported account types and Redirect URI, located under the Authentication tab. If these settings are configured incorrectly, you’ll likely experience issues authorizing WP Mail SMTP.
As soon as this registration form is submitted, you’ll be redirected to the Overview page. Here, you’ll find your Application (client) ID. Go ahead and copy this value.

Once you have the Application (client) ID copied, you’ll need to paste this full value into your WP Mail SMTP settings, in the field labeled Application ID.

Create an Application Password
Next, we’ll need to generate a password for this app. To do that, go to Manage » Certificates & secrets in the left sidebar within the app you registered.

Note: You’ll need to be in the app directory you created to see the Certificates & secrets option. You can access this page by navigating to App registrations and selecting the app name you registered.
On this screen, click on the + New client secret option.

An overlay will appear, and here you’ll need to fill out a short form:
- Description: This name is only for your own use, so we recommend a logical and simple name, such as
app_password
. - Expires: 730 days (24 months).

After you submit the client secret form, the Application Password will be generated. Go ahead and copy the password under the Value column (not the Secret ID column), and head back over to your WP Mail SMTP settings.

Note: You won’t be able to access the Value after you exit this page. We recommend storing the value in a secure location in case you need to access it again.
Once you’ve returned to the tab or window where your settings are still open, paste this value into the Application Password field.

Saving Settings and Authorizing WP Mail SMTP
Once you’ve added your Application ID and Application Password, click the Save Settings button at the bottom of the page.

After you’ve saved the settings, you’ll need to scroll down to the Authorization section. You should now see a button labeled Allow plugin to send emails using your Microsoft account. Go ahead and click this button.

Once you’ve clicked the button, you should be redirected to a Microsoft permissions form.

At the bottom of this form, click Yes.
Next, you will be redirected back to your WP Mail SMTP settings. At the top of these settings, you should see a notification letting you know that you’ve successfully connected your Microsoft account.

Then, in the Authorization section at the bottom of the page, you should also see the name and email address that you used to authorize the connection.

From Email
Now that your Microsoft API is set up and connected, you can now enter a From Email address. You will need to use the same email address that you used to authorize your connection. This email address can be found in the Authorization section of your settings.

Go ahead and enter this same email address in the From Email address field in your settings.
Note: If you’d like to send emails as a different user, shared inbox, or group, be sure to check out our FAQ section to learn how.
We also strongly recommend checking the Force From Email box. Selecting this option will prevent you from having to edit the From Email settings in other areas of your site.

Note: For more details, see our guide to understand how the Force From Email setting works.
From Name
The Microsoft 365 / Outlook.com mailer doesn’t support changing or forcing the From Name. Your emails will be sent on behalf of the account name used to authorize the connection.

Backup Connection
Setting up a Backup Connection is optional and isn’t required to complete your Microsoft 365 / Outlook mailer setup. However, to further improve email deliverability, we recommend configuring an additional connection to serve as a backup in case your Primary Connection fails.

Note: Want to route your emails through a specific additional connection based on a set of rules or conditions? Be sure to check out our tutorial on Smart Routing to learn how.
Sending a Test Email
Now that your Microsoft API is set up and connected, it’s important to send a test email to ensure that everything is working properly. To do this from the WordPress admin dashboard, go to WP Mail SMTP » Tools and click on the Email Test tab.

In the Send To field, you’ll see the site’s admin email address by default. However, feel free to change this email address to any email address you’d like to send the test email to.
Note: If you’ve set up an additional connection, you’d be able to choose between your Primary Connection and other connections when sending a test email.
Next, click the Send Email button to send your test email.

After sending the email, you should see a success message.

If you check the inbox for that email address, you should receive the email for this test.
