4.1.2. Domains
💡 First Principle: A domain proves identity on the internet. Microsoft can only issue email addresses and sign-in names for a domain you've proven you control — which is why every custom domain starts with a DNS record that only the domain's owner could create.
Adding and verifying a domain — Microsoft 365 admin center > Settings > Domains > Add domain (or Entra ID > Domain names), as at least a Domain Name Administrator:
- Verification uses a TXT record by preference; an MX record with a high preference value (so it doesn't take mail) if you can't add TXT; or a text file at the website root. Verification usually takes minutes, but can take up to 48 hours with some registrars.
- A domain can be verified in only one tenant at a time — to move it, remove it from the old tenant first.
- Create users and mailboxes before switching MX. Once MX points at Microsoft 365, all mail for the domain arrives there. Keep a single SPF TXT record, adding Microsoft 365's values to any existing one.
- Subdomains of a verified domain are verified automatically.
The default domain (Settings > Domains > select > Set as default) is used for new accounts. Changing it affects new accounts only — existing users keep their UPNs until you change them. A federated domain can't be the primary domain in Entra.
The onmicrosoft.com domain — the initial *.onmicrosoft.com domain created with the tenant can't be removed or renamed. You can add more onmicrosoft.com domains (up to five in total) and choose one as the fallback domain, but onmicrosoft.com domains can't be deleted once created, and changing the fallback domain doesn't rename SharePoint URLs. Sending from onmicrosoft.com addresses is limited to 100 external recipients a day, so use them for testing only.
Removing a domain requires that it isn't the default and that nothing uses it — no users, shared or resource mailboxes, contacts, groups or teams, and no admin signing in with it. Move users (Users > Active users > Change domains) and groups first, then Settings > Domains > Remove domain. When a domain is removed, affected accounts fall back to their onmicrosoft.com addresses. In Entra, ForceDelete renames references automatically, but it doesn't work for federated domains.
Managed vs federated. A managed domain authenticates in the cloud (password hash sync or pass-through authentication); a federated domain hands sign-in to another system such as AD FS. Microsoft recommends enabling password hash sync even for federated domains, as a backup and for leaked-credential detection.
⚠️ Exam Trap: "After making contoso.com the default domain, all users now sign in as user@contoso.com" is false — only new accounts get the default domain. And no sequence of steps removes the original onmicrosoft.com domain.
Reflection Question: Contoso acquires Fabrikam and wants Fabrikam's users to keep their @fabrikam.com addresses in the Contoso tenant. Fabrikam's domain is still verified in Fabrikam's old tenant. What must happen first, and why?