# Microsoft 365 / Outlook

> Connect Microsoft 365 or Outlook.com to BooleanSMTP through Microsoft Graph with an Azure app registration, then send a test email.

BooleanSMTP connects to Microsoft 365 or Outlook.com through the **Microsoft Graph API** only —
there is no SMTP mode. Microsoft has disabled SMTP AUTH Basic Authentication by default on new
tenants, and there is no app-password equivalent for a Microsoft 365 mailbox, so Graph is the only
path.

## Before you begin

- Access to the [Microsoft Entra admin center](https://entra.microsoft.com/) to register an app.
- The mailbox address you'll send from — a personal `outlook.com` / `hotmail.com` / `live.com` /
  `msn.com` mailbox and a paid Microsoft 365 work/school mailbox both work.

## Add the connection

<Steps>

1. In the [Microsoft Entra admin center](https://entra.microsoft.com/), go to **App registrations →
   New registration** and register a **Web** app, using the account type based on who should sign in
   (see [Tenant ID](#tenant-id) below).
2. Under **Redirect URI**, paste the exact value BooleanSMTP shows on the connection form (step 6).
3. Go to **Certificates & secrets → New client secret**, and copy the **Value** immediately —
   Microsoft shows it once.
4. Go to **API permissions → Add a permission → Microsoft Graph → Delegated permissions**, and add
   `Mail.Send`, `User.Read`, and `offline_access` (add `Mail.Send.Shared` too for a shared mailbox).
5. In your WordPress admin, go to **BooleanSMTP → Mailers**, click **Add Connection**, and choose
   **Microsoft Outlook**.
6. Under **Sender Settings**, fill in **From Email** and **From Name**, then fill in **Client ID**
   and **Client Secret** from step 3, and set **Tenant ID** (see below).
7. Click **Authorize**, complete Microsoft's consent screen, then click **Register Connection**.

</Steps>

![The Microsoft Outlook connection form, with Client ID, Client Secret, Tenant ID and Send as a shared mailbox fields, and the Authorize button.](../../../assets/screenshots/outlook.webp)

### Tenant ID

Leave **Tenant ID** as **common** unless you need to restrict sign-in to one organization — then use
your tenant's GUID (Entra admin center → your app → **Overview** → **Directory (tenant) ID**).
BooleanSMTP then shows a **Grant admin consent for your organization** link so an administrator can
approve the app for everyone at once.

### Sending as a shared mailbox

Enable **Send as a shared mailbox**, set **From Email** to the shared mailbox's address, and
authorize with an account that has Exchange **"Send As"** or **"Send on behalf"** rights to that
mailbox — not the shared mailbox's own login.

## Send a test email

Use **Test Email** in the sidebar to confirm the connection works — see
[Send a test email](/getting-started/send-a-test-email/) for the steps.

## Common errors

- **"redirect_uri_mismatch"** — the URI pasted into the Entra app registration doesn't exactly match
  the one BooleanSMTP shows on the connection form.
- **401 with an empty body on `/me/sendMail`, but `/me` returns 200** — the signed-in identity has no
  mailbox in this tenant (often a guest `#EXT#` account); reconnect with a mailbox-enabled account.
- **"...does not have the right to send mail on behalf of the specified sending account"** — the
  authorizing account lacks Exchange delegate rights to the mailbox in **From Email**; see
  [Sending as a shared mailbox](#sending-as-a-shared-mailbox) above.

## Next steps

- [Send a test email](/getting-started/send-a-test-email/)
- [Set a fallback connection](/sending/fallback-and-retries/)
- [Check delivery in Logs](/logs/)
- [Set up alerts](/alerts/)
