Home › Guides › Email & data

SPF, DKIM, and DMARC for Microsoft 365: Plain-English Setup for Small Businesses (2026)

By Justin N. · Updated 2026-10-22 · This page may contain affiliate links

If your email is landing in customers' junk folders, or someone is sending fake invoices "from" your domain, these three DNS records are the fix. Microsoft 365 does part of the work automatically. The rest is about 30 minutes in your DNS host, plus a few weeks of patience on DMARC.

Who this is for: a small business that sends email from its own domain (like [email protected]) through Microsoft 365. You'll need access to your DNS host (often your domain registrar) and an admin account for the Microsoft Defender portal. Record formats below are from Microsoft Learn, checked 2026-10-22.

What these three records do

Microsoft's order is SPF, then DKIM, then DMARC. Its DMARC guide says to create SPF records and configure DKIM for every custom domain you send from before you configure DMARC. (Set up DMARC)

Before you start: list everything that sends as your domain

This is the step people skip, and it's the reason DMARC breaks things later. Write down every service that sends email using your domain in the From address:

For bulk-email services you don't control, Microsoft recommends sending from a subdomain (for example news.yourcompany.com) so their reputation can't hurt your main domain. (Set up DMARC)

Step 1: SPF

If Microsoft 365 is your only sender, Microsoft's recommended SPF TXT record at the root of your domain is:

v=spf1 include:spf.protection.outlook.com -all

Rules Microsoft spells out (Set up SPF):

Example with a second sender (the include value comes from that service's own instructions):

v=spf1 include:spf.protection.outlook.com include:<your-other-service> -all

Where you add the record depends on your DNS host. Microsoft has generic steps for any provider in Add DNS records to connect your domain.

DNS host: if you're still choosing one, any registrar that lets you edit TXT and CNAME records will work. Microsoft's generic steps apply to all of them.

Step 2: DKIM

Microsoft already signs mail sent from your *.onmicrosoft.com address. For your custom domain, you turn DKIM on yourself (Set up DKIM):

  1. In the Microsoft Defender portal (security.microsoft.com), go to Email & collaboration > Policies & rules > Threat policies > Email authentication settings, then open the DKIM tab.
  2. Select your custom domain. If its status says No DKIM keys saved for this domain, select Create DKIM keys.
  3. The flyout shows two CNAME records, selector1._domainkey and selector2._domainkey. Copy the values exactly as shown. Microsoft says the values in its article are for illustration only, and the current format includes a character Microsoft assigns per domain. For example, the target looks like selector1-yourcompany-com._domainkey.yourtenant.n-v1.dkim.mail.microsoft, but yours may differ.
  4. Create both CNAME records at your DNS host.
  5. Wait for DNS to update, return to the domain's flyout, and turn on Sign messages for this domain with DKIM signatures. Until DNS catches up, the status may show CnameMissing.

If you prefer PowerShell, Microsoft documents this command (Exchange Online PowerShell) to show the exact CNAME values for a domain:

Get-DkimSigningConfig -Identity yourcompany.com | Format-List Name,Enabled,Status,Selector1CNAME,Selector2CNAME

Third-party senders need DKIM too. Your newsletter or invoicing tool must sign with your domain (or a subdomain of it), not its own. Otherwise SPF can pass and DMARC still fails, because the domains don't align. Microsoft's DMARC troubleshooting table lists this as a top cause. Look for "custom domain authentication" or "DKIM" in that tool's settings.

Step 3: DMARC, slowly

You create DMARC as a TXT record named _dmarc at your DNS host. Microsoft 365 has no admin page for custom-domain DMARC records. Microsoft recommends a gradual rollout (Set up DMARC):

StageTXT value for _dmarcWhat it does
1. Monitorv=DMARC1; p=none; rua=mailto:[email protected]No action on failures. You just collect reports.
2. Quarantinev=DMARC1; p=quarantine; pct=10; rua=mailto:[email protected]Failing mail is marked as junk or quarantined. Raise pct through 25, 50, 75, then 100.
3. Rejectv=DMARC1; p=reject; rua=mailto:[email protected]Failing mail is typically rejected. This is the goal state.

Microsoft doesn't put a fixed number of weeks on each stage. It says to move on "after enough time monitoring." My rule of thumb: wait until at least a full billing cycle has passed in the reports so monthly senders (invoices, statements) show up. Microsoft also suggests starting with a domain or subdomain that has low mail volume and few senders.

Where reports go: Microsoft recommends a dedicated mailbox or Microsoft 365 Group for reports, not someone's personal inbox. A shared mailbox works well and doesn't need a license under 50 GB.

Why reject matters for your outbound mail: Microsoft says outbound messages from Microsoft 365 that fail DMARC at the destination are routed through its high-risk delivery pool if your policy is p=quarantine or p=reject. That's one more reason to fix alignment for every sender before you tighten the policy.

Don't forget: onmicrosoft.com and parked domains

Reading DMARC reports without losing your mind

Aggregate reports arrive as compressed XML attachments, usually about once a day per receiving provider. Microsoft notes that "the information in the Aggregate report can be vast and difficult to parse," and suggests either building your own automation or using a DMARC reporting service. It points to the Microsoft Intelligent Security Association (MISA) catalog to find one. Two facts worth knowing:

Reporting services that turn the XML into a readable dashboard include EasyDMARC. Check current plans and pricing on the vendor's own site. If you use a service like this, it typically gives you its own rua= address to put in your record. Microsoft notes that reporting services describe any custom values their DMARC record needs.

Quick troubleshooting

SymptomLikely cause (per Microsoft)Fix
SPF and DKIM both pass, DMARC failsNeither domain aligns with the From domainHave the sending service sign DKIM with your domain, or use your domain or a subdomain as its MAIL FROM
"Too many lookups" bouncesSPF over 10 DNS lookupsRemove unused includes and move bulk senders to a subdomain
dmarc=permerrorDMARC record syntax error, or more than one _dmarc recordKeep exactly one _dmarc TXT record and check the syntax
No aggregate reports arrivingReport mailbox unreachable, or reports going to a different domain without authorizationFix the mailbox. For an external report domain, that domain must publish a yourdomain._report._dmarc TXT record

For a full list, see Troubleshoot email authentication in Microsoft 365.

Sources

Tools mentioned: DMARC reporting services such as EasyDMARC, or the MISA catalog to find others. These are ordinary links, not affiliate links.

Accuracy note: Microsoft changes admin center menus and licensing often. Paths and prices were checked against Microsoft documentation on 2026-10-22. If something has moved, tell me at [email protected].