Exchange Online mailboxes and email authentication
Manage mailboxes, aliases, groups and delegation, trace messages, and plan SPF, DKIM and DMARC in stages.
By Invicly Tech, , in Microsoft Entra & Microsoft 365 Administration. About 12 minutes to read.
In short
Exchange Online runs your organisation's mailboxes in the cloud. Admins create and change mailboxes, add aliases, set up shared mailboxes and distribution lists, grant delegated access and trace messages that went missing. They also publish SPF, DKIM and DMARC records in stages so other mail systems can trust mail from your domain.
Think of it like this: SPF is the list of approved post offices, DKIM is a wax seal on each letter, and DMARC tells receivers what to do when the seal or post office is wrong.
Explained simply
Exchange Online is Microsoft's cloud email service. Each licensed user gets a mailbox with mail, a calendar and contacts. As an admin you create mailboxes, change addresses, set up shared inboxes and lists, and decide who may open or send from someone else's mailbox.
A mailbox can have more than one address. The main one is the primary address. Extra ones are aliases. Mail sent to an alias lands in the same inbox. This is handy when someone changes their name, or when you want sales@contoso.com to reach one person for now.
When several people answer the same inbox, use a shared mailbox. Nobody signs in to it directly. Instead you give people permission, and it appears in their Outlook. A distribution list is different: it has no inbox, it just copies each message to its members.
When someone says an email never arrived, message trace tells you what happened. It shows whether Microsoft received the message, delivered it, marked it as spam, quarantined it or failed to deliver it. That turns guessing into facts.
SPF, DKIM and DMARC are DNS records that help other mail systems trust mail from your domain and reject fakes. Add them in stages. If you switch on strict rules too soon, real mail from forgotten systems can be blocked.
Press Play on a diagram to walk through it one step at a time.
- One inbox many people read
- No sign-in of its own
- No licence needed up to 50 GB
- Access via Full Access and Send As
- An address that copies mail to members
- No inbox or stored mail
- Good for announcements
- Members get their own copy
- Shared inbox, calendar and files
- Backs a Team or SharePoint site
- Owners manage membership
- Good for project teams
- 1SPF with ~all
List every system that sends as your domain
- 2Enable DKIM
Publish two CNAMEs, then turn signing on
- 3DMARC p=none
Collect reports, change nothing yet
- 4Fix unknown senders
Add or remove sources the reports reveal
- 5Tighten
Move to p=quarantine, then p=reject
- Delivered
- Inbox rules
- Junk Email folder
- Focused or Other tab
- FilteredAsSpam or Quarantined
- Defender quarantine
- Anti-spam policy
- Release if safe
- Failed
- Trace detail event
- Recipient or transport rule
- Non-delivery report
- No result
- Wrong time window
- Sender never sent
- MX record or sender DNS
In depth
Mailboxes, aliases and recipients
Exchange calls anything that can receive mail a recipient. User mailboxes belong to licensed users. Shared mailboxes, room mailboxes and equipment mailboxes have no licence by default and nobody signs in to them. Mail users and mail contacts point to addresses outside your organisation.
Each mailbox has a list of proxy addresses. The one written SMTP in capitals is the primary address used when sending; lower-case smtp entries are aliases that only receive. When a person changes their name, add the new address, make it primary and keep the old one as an alias so mail sent to it still arrives. You can make these changes in the Exchange admin center under Recipients > Mailboxes, or with Set-Mailbox in Exchange Online PowerShell.
- SMTP: primary, used to send
- smtp: alias, receive only
- Shared mailbox: free up to 50 GB, no archive
- Room mailbox: books meeting rooms
Delegation: Full Access, Send As and Send on Behalf
Delegation lets one person work with another mailbox. Full Access lets them open the mailbox and read everything, but not send from it. Send As lets them send mail that looks exactly like it came from the mailbox. Send on Behalf shows both names, such as Ana on behalf of Sales. Most shared mailboxes need Full Access plus Send As.
Full Access granted with automapping makes the mailbox appear in the user's Outlook after a while, often within an hour. Permissions on a group are possible but automapping does not work through groups. Record who has access and why, and review it, since shared mailboxes often collect people who left the team long ago.
- Open and read the mailbox
- Cannot send by itself
- Add-MailboxPermission
- Automapping into Outlook
- Sender looks like the mailbox
- No sign of the real sender
- Add-RecipientPermission
- Common for shared inboxes
- Shows delegate on behalf of owner
- Visible to recipients
- Set-Mailbox -GrantSendOnBehalfTo
- Common for assistants
Tracing a message
In the Exchange admin center, go to Mail flow > Message trace and search by sender, recipient and time. In PowerShell, use Get-MessageTraceV2, which replaced the older Get-MessageTrace. It covers the last 90 days, returns the last 48 hours if you give no dates, and allows up to 10 days per query.
Read the status. Delivered means it reached the mailbox, so look at the user's rules, Junk folder or Focused Inbox. FilteredAsSpam or Quarantined means a filter caught it; check the quarantine in Microsoft Defender. Failed means delivery was attempted and refused, and the detail often names the reason. No result at all usually means the message never reached Microsoft, so the sender's side or DNS is the place to look.
- Delivered: check user rules and Junk
- Quarantined: check Defender quarantine
- Failed: read the detail event
- No result: check sender and MX record
- Times are shown in UTC
SPF, DKIM and DMARC in stages
SPF is a TXT record listing who may send as your domain, such as v=spf1 include:spf.protection.outlook.com -all. Add every other sender, like a newsletter or billing tool. Keep one SPF record only and stay under 10 DNS lookups.
DKIM adds a signature to each message. For a custom domain, run Get-DkimSigningConfig to see the two CNAME values for selector1 and selector2, publish them, then turn signing on in the Defender portal or with Set-DkimSigningConfig. Do not guess the CNAME targets; Microsoft has more than one format.
DMARC is a TXT record at _dmarc.contoso.com. Start with p=none and a rua address to receive reports. Read the reports for a few weeks, fix or add missing senders, then move to p=quarantine and finally p=reject. Keep a rollback: lowering the policy back to p=none takes effect as DNS caches expire.
Learn it in 5 short steps
About 40m each. Track them with a timer in your plan.
- 1Manage mailboxes and aliases~40m
- 2Create shared mailboxes and lists~40m
- 3Delegate mailbox access~40m
- 4Trace a message~40m
- 5Stage SPF, DKIM and DMARC~40m
Key points
- An alias is an extra address on the same mailbox; it does not create a new mailbox.
- Full Access lets someone open a mailbox; Send As and Send on Behalf control how they send.
- Message trace shows whether Microsoft received, delivered, filtered or failed a message.
- SPF allows at most 10 DNS lookups; too many includes break it.
- Start DMARC at p=none and only tighten once reports show all real senders pass.
Key terms
Tap a card to flip it. 0/6 known
Examples
Connect-ExchangeOnline -UserPrincipalName admin@contoso.com
# Add an alias to an existing mailbox
Set-Mailbox -Identity ana -EmailAddresses @{Add="ana.lopez@contoso.com"}
# Create a shared mailbox and give Ana access
New-Mailbox -Shared -Name "Sales" -Alias sales
Add-MailboxPermission -Identity sales -User ana -AccessRights FullAccess
Add-RecipientPermission -Identity sales -Trustee ana -AccessRights SendAs -Confirm:$falseUses the ExchangeOnlineManagement module with a lab tenant and fictional users.
Name change without losing mail
Ana Lopez marries and becomes Ana Silva. Step 1: in the Exchange admin center, open her mailbox and add ana.silva@contoso.com. Step 2: make it the primary address. Step 3: keep ana.lopez@contoso.com as an alias so old contacts still reach her. Step 4: update her display name and, in Entra, her user principal name if your policy requires it, and tell her to sign in with the new name. Step 5: check with Get-EXOMailbox that both addresses are listed. Rollback: switch the primary back.
Connect-ExchangeOnline -UserPrincipalName admin@contoso.com
Set-Mailbox -Identity ana.lopez@contoso.com `
-EmailAddresses @{Add="SMTP:ana.silva@contoso.com"}
Get-EXOMailbox -Identity ana.silva@contoso.com |
Select-Object -ExpandProperty EmailAddressesStaging DMARC for fabrikam.com
Week 1: confirm SPF lists Microsoft 365 and the billing tool, and enable DKIM for fabrikam.com. Week 1: publish _dmarc.fabrikam.com as v=DMARC1; p=none; rua=mailto:dmarc@fabrikam.com. Weeks 2 to 4: reports show a survey tool sending as fabrikam.com and failing. Configure that tool to sign with DKIM for your domain, or move it to a subdomain. Week 5: change to p=quarantine; pct=25. Week 7: p=quarantine at 100 percent. Week 9: p=reject. Evidence at each step: the aggregate reports show the pass rate for each source.
fabrikam.com TXT "v=spf1 include:spf.protection.outlook.com include:billing.example.com -all"
_dmarc.fabrikam.com TXT "v=DMARC1; p=none; rua=mailto:dmarc@fabrikam.com"
# later
_dmarc.fabrikam.com TXT "v=DMARC1; p=quarantine; pct=25; rua=mailto:dmarc@fabrikam.com"
# finally
_dmarc.fabrikam.com TXT "v=DMARC1; p=reject; rua=mailto:dmarc@fabrikam.com"Quick reference
- Connect: Connect-ExchangeOnline (ExchangeOnlineManagement module)
- Alias: Set-Mailbox -EmailAddresses @{Add="smtp:alias@contoso.com"}
- Shared mailbox: New-Mailbox -Shared; no licence needed up to 50 GB
- Full Access: Add-MailboxPermission; Send As: Add-RecipientPermission
- Trace: Get-MessageTraceV2, 90 days back, 10 days per query
- One SPF record per domain, maximum 10 DNS lookups
- DKIM: read Selector1CNAME and Selector2CNAME from Get-DkimSigningConfig
- DMARC: p=none, then quarantine, then reject
Common mistakes
- Publishing a second SPF record instead of editing the first; two SPF records make SPF fail.
- Jumping straight to DMARC p=reject and blocking a forgotten sender such as a billing system.
- Converting a shared mailbox to a user mailbox and back without checking licence and size limits.
Quick quiz
Pick an answer to see if you're right and why.
Practice exercises
Try each one yourself first. Use the hint if you get stuck, then compare with the solution.
- Exercise 1easy
In a trial tenant, create a shared mailbox called Support and give a test user Full Access and Send As. Confirm it appears in their Outlook on the web.
- Exercise 2medium
Send a test message from an outside address to a test user, then trace it with PowerShell and record its status and Message trace ID.
- Exercise 3hard
Write a staged email authentication plan for contoso.com that also sends mail through a marketing tool. Include records, dates, evidence and rollback.
Check yourself
Answer in your head, reveal, then be honest with yourself.
Feel confident about this topic?
Frequently asked questions
- Does a shared mailbox need a licence?
- Not usually. It needs one if it grows past 50 GB, needs an online archive, or needs certain hold features.
- What is the difference between a distribution list and a Microsoft 365 group?
- A distribution list only forwards mail to members. A Microsoft 365 group adds a shared inbox, calendar, files and can back a Team.
- Is Get-MessageTrace still the right cmdlet?
- No. Microsoft replaced it with Get-MessageTraceV2 and Get-MessageTraceDetailV2, which use a 10-day window per query over 90 days of data.
- Will DMARC stop all phishing?
- No. It stops others from sending as your exact domain. Look-alike domains and compromised accounts need other defences.