How do I connect my domain to Microsoft 365?
Add the MS=ms value as a TXT record on the DNS tab, paste the MX value Microsoft shows into Quick setup on the Email tab, add the autodiscover and two DKIM CNAME records by hand, then give your users addresses on your domain instead of onmicrosoft.com.
Publisert 19. november 2026
Les denne på norskConnecting your domain to Microsoft 365 (formerly Office 365) takes four steps, in Microsoft's order. First, add the domain in the Microsoft 365 admin center and prove it is yours with a TXT record on @ holding Microsoft's MS=ms value. Second, paste Microsoft's MX value into Quick setup on the Email tab for the MX and SPF records, and add the autodiscover CNAME yourself. Third, add two DKIM CNAME records and switch signing on in the Microsoft Defender portal. Last, give your users addresses on your domain instead of onmicrosoft.com. We have no link to Microsoft: you copy each value across and confirm each step there, and nothing changes in your DNS until you click Apply.
Before you start
- A Microsoft 365 business or enterprise plan. We sell the domain; the plan and the mailboxes come from Microsoft. Personal and Family can't use a domain registered with us: "At the moment, we only support connecting domains managed by GoDaddy with Outlook.com."
- The Domain Name Administrator role in Microsoft. Ordinary users and customised administrators can't add a domain.
- The domain on our nameservers, ns1.sedes.no to ns4.sedes.no. If it isn't, the Email and DNS tabs say so, and nothing you save there takes effect. A domain you moved to us keeps its old nameservers until you change them. If its DNS is run elsewhere on purpose, the records belong there: see Can I move just my .no to Sedes and keep my other domains at Domeneshop? and How do I move my .no domain to Sedes?
- You are the holder (the person or organisation the domain is registered to), or an administrator of the organisation that holds it. Anyone else is turned away at Apply (see "Apply is refused").
- Mail already arrives on this domain somewhere else? Read the stop at the top of step 2 first, and "Will I lose email when I switch?"
1. Prove the domain is yours (the MS=ms TXT record)
Already have Microsoft's MS=ms value? Copy it and skip to the Sedes part.
In the Microsoft 365 admin center:
- In the left bar, choose … Show all → Settings → Domains.
- Click + Add domain, type your domain in Domain name and click Use this domain.
- On Verify you own your domain, choose Add a TXT record to the domain's DNS records and click Continue. We don't support Domain Connect, so if Microsoft names a registrar and offers to sign you in there, select choose a different domain host, then the TXT option.
- Copy the value on Add a record to verify ownership: a TXT record on
@that "looks like this: MS=msXXXXXXXX." Leave the page open.
In your Sedes account:
- At app.sedes.no, open Domains, click the domain, open the DNS tab and click New record.
- Set Host to
@(the domain itself) and Type to TXT, and paste the value into Data without quotation marks; we add those when publishing. Leave TTL at 3600. - Click Save 1 change, check the record under Added in Review changes, and click Apply 1 change.
Save only shows the changes; Apply publishes them. Save counts the rows you added, changed or removed. Apply counts the lines in Review changes, where a changed record shows twice, old value under Removed and new under Added, so Apply can show more. A saved TXT record is listed under Advanced, not Simple.
Back in Microsoft, click Verify. If the record isn't found yet, wait and click again (see "How long does it take?"). Once the domain is verified, Microsoft says to remove the record; it is used only to prove you own the domain. Delete its row under Advanced, then Save and Apply.
2. Send your mail to Microsoft 365 (MX, SPF and autodiscover)
Mail arrives on this domain somewhere else today? Stop once the domain is verified. Before the MX record changes, everyone who gets mail on the domain needs a Microsoft 365 user with an address on it, so email keeps working. Do step 4 now and add anyone still missing. Then come back through Settings → Domains → the domain → DNS records → Manage DNS (also the way back later). With a new domain, carry on.
In the Microsoft 365 admin center:
- On How do you want to connect your domain?, click Continue, or open More options, choose Add your own DNS records and click Continue.
- On Add DNS records, keep Exchange and Exchange Online Protection selected and expand MX Records, CNAME Records and TXT Records. Leave the page open.
The MX value is your domain's own and may end in mail.protection.outlook.com or in mx.microsoft, which Microsoft is moving new domains to. Copy what you see.
Don't add Microsoft's SPF row as a new record. A domain should have a single SPF record, and Quick setup edits yours or adds Microsoft's, v=spf1 include:spf.protection.outlook.com -all.
In your Sedes account:
- On the Email tab, click Microsoft 365 on the Quick setup row. In the field The MX value from Microsoft 365, paste the value from Microsoft's MX row, host name only, and click Add.
- A new MX row appears on
@with priority 0. Other MX rows on@are struck through, each undoable until you save; those on subdomains stay. - Quick setup also handles SPF. With none, it adds Microsoft's. Into an existing one it puts
include:spf.protection.outlook.combefore the~allor-all, keeping the rest; two SPF records it merges into one. The Email tab lists MX only, so the SPF change shows in Review changes. - Click Save, which reads Save 2 changes on a domain with no mail records yet. Check MX and SPF under Added and any old MX rows under Removed, then click Apply.
Quick setup does MX and SPF only. Add the autodiscover record by hand. Microsoft calls it "optional but highly recommended": it lets Outlook set up a user's email automatically. On the DNS tab, click New record: Host autodiscover, Type CNAME, Data Microsoft's value, autodiscover.outlook.com. Save, then Apply. If the domain already has an autodiscover row from an earlier provider, set that row's Type to CNAME and its Data to Microsoft's value instead of adding a second.
Back in Microsoft, click Continue. When Microsoft finds the records, it shows Domain setup is complete; click Done. If not, wait and click Continue again.
3. Sign the mail you send (DKIM)
Microsoft signs your onmicrosoft.com mail with DKIM by itself, but not your own domain's. Microsoft calls these records optional, yet without them your domain's mail goes out unsigned.
In the Microsoft Defender portal:
- Open https://security.microsoft.com/authentication and choose the DKIM tab.
- In your domain's row, slide Toggle to Enabled. A Client error dialog shows the two CNAME values; that is expected. Click OK, and the status becomes CnameMissing.
- Click the row, not the toggle, to open its details. Copy the two values under Publish CNAMEs and leave the details open.
Copy the values, don't build them; Microsoft's own examples "are for illustration only."
In your Sedes account, on the DNS tab, add two rows with New record: Host selector1._domainkey and selector2._domainkey, nothing after them, Type CNAME, Microsoft's value for each in Data. Add both, even though Microsoft uses only one at a time. A final dot on the value or none makes no difference; we add it when missing. Click Save 2 changes, then Apply 2 changes.
Back in the Defender portal, in the same details: once Microsoft has seen the records (see "How long does it take?"), slide Sign messages for this domain with DKIM signatures on. It is done when the status reads Signing DKIM signatures for this domain.
4. Move your addresses off onmicrosoft.com
If you stopped at the top of step 2, this is already done.
The <name>.onmicrosoft.com domain your organisation got at sign-up, and used until you added yours, can't be removed and still works for email; you just needn't use it.
- For new accounts, go to Settings → Domains, select your domain and click Set as default. That only affects accounts you create afterwards.
- For existing users, a global admin goes to Users → Active users, selects each user and changes the username to your domain. A user without an Exchange licence can't use the domain for email.
Teams and Intune records (only if Microsoft lists them)
Under Advanced options on Add DNS records, Microsoft lists records for other services. None is needed for mail; add one only if Microsoft lists it for a service you use.
- Teams: one SRV record. It goes in as Host
_sipfederationtls._tcp, Type SRV, Prio100and Data1 5061 sipfed.online.lync.com(weight, port, target), the form Microsoft gives for DNS hosts without separate service and protocol fields. - Intune: two CNAME records,
enterpriseregistrationpointing toenterpriseregistration.windows.netandenterpriseenrollmentpointing toenterpriseenrollment-s.manage.microsoft.com.
The records
… stands for the value Microsoft shows you.
| Step | Host | Type | Prio | Data | Who adds it |
|---|---|---|---|---|---|
| Verify | @ | TXT | MS=ms… | You, DNS tab | |
| Receive mail | @ | MX | 0 | Microsoft's value, ending in mail.protection.outlook.com or mx.microsoft | Quick setup |
| SPF | @ | TXT | v=spf1 include:spf.protection.outlook.com -all, or added to your existing SPF | Quick setup (don't add it yourself) | |
| Outlook setup | autodiscover | CNAME | autodiscover.outlook.com | You, DNS tab | |
| DKIM | selector1._domainkey | CNAME | Microsoft's selector1 value | You, DNS tab | |
| DKIM | selector2._domainkey | CNAME | Microsoft's selector2 value | You, DNS tab |
Leave TTL at the app's 3600, which is what Microsoft gives for every record here.
Will I lose email when I switch?
Not if the domain has no email yet: a domain newly registered with us has no mail records, so there is nothing to lose.
If mail arrives somewhere else today, do the stop at the top of step 2 first. Once the MX record points to Microsoft, all new email for your domain goes to Microsoft 365. Old email stays at your previous provider unless you migrate it, which is done on Microsoft's side.
Does the domain have to move to Microsoft?
No. The domain stays registered with us, and its DNS stays on our nameservers; in Microsoft's terms, we are your DNS host. Your website is not touched: none of these records is on www or the domain's A record.
How long does it take?
Our nameservers answer with a new record as soon as you click Apply; DNS servers that cached an older answer catch up as it expires. The DNS propagation panel on the DNS tab shows what public resolvers answer now (Refresh checks again).
At Microsoft:
- Verification: "It can take up to 10 minutes to verify domain ownership after adding the TXT record. Some registrars might require additional time up to 48 hours."
- Mail records: Microsoft gives no time; it checks when you click Continue.
- DKIM: "It takes a few minutes (or possibly longer) for Microsoft 365 to detect the new CNAME records you created." Propagation "can take a few minutes to 48 hours".
When it doesn't work
Microsoft can't find the MS=ms record
Under Advanced on the DNS tab, check that a TXT record on @ holds the whole MS=ms… value, without quotation marks, and that the Nameservers tab lists ns1.sedes.no to ns4.sedes.no. Give Microsoft its time, then click Verify again. If the record is there and Microsoft still can't see it, email hei@sedes.no with the domain name.
Quick setup won't take the MX value
The message reads: "Paste the host name as Microsoft shows it, for example example-com.mail.protection.outlook.com." The field takes a host name only: no spaces, no priority number, no http://. If it refuses a value exactly as Microsoft shows it, email hei@sedes.no with the value.
Mail still goes to the old provider
On the Email tab, the only MX row on @ should be Microsoft's; Microsoft says to remove MX records pointing to a previous provider. If there are others, click Microsoft 365 under Quick setup again and paste the same value: Microsoft's row stays and the others are struck through. Save and Apply. Check the Nameservers tab and the DNS propagation panel, then click Continue in Microsoft again. If Microsoft's row is the only one and mail still goes astray, email hei@sedes.no with the domain name.
DKIM stays on CnameMissing
Microsoft's list of causes:
- The host has the domain typed after it. Microsoft: "Enter only selector1._domainkey" (or
selector2._domainkey). - The selector2 record is missing.
- The record is a TXT instead of a CNAME, which Microsoft doesn't support.
- The TTL is too low. Leave ours at 3600.
- The value was typed by hand instead of copied.
If the status is still CnameMissing after 48 hours, Microsoft says the records are wrong or in the wrong place. If both rows match Microsoft's values, email hei@sedes.no with the domain name.
Apply is refused
The message reads: "Only the domain's holder can save changes. If the holder is an organisation, an administrator of that organisation can do it." Ask one of them to make the change. If you are the holder and still see it, email hei@sedes.no. Do the same if "Could not save the changes. Please try again." comes back when you try again.
Nothing you save makes any difference
If the Email or DNS tab says the domain uses other nameservers than ours, nothing you save here takes effect until it uses ns1.sedes.no to ns4.sedes.no. Change them under Nameservers, or add the records where the domain's DNS is run now. Not sure where that is? Email hei@sedes.no with the domain name.
How this actually works
The domain is the address; the mailbox is at Microsoft. The verification TXT proves you control the domain. MX tells other mail servers to deliver to Microsoft. Autodiscover lets Outlook find its settings by itself. SPF says Microsoft's servers may send for your domain. The two DKIM records point to Microsoft, so Microsoft can sign what you send and receivers can check it.
All of them live in the DNS we run for your domain. Microsoft only reads them and changes none; with no Domain Connect, nothing goes from us to Microsoft, so you copy the values across.
More on MX priority: What is an MX record, and what does the priority number do? Record types, TTL and propagation: Your domain's DNS settings, explained.
Not covered here: moving old mail into Microsoft 365, and DMARC.
Sources: Microsoft Learn on adding a domain, DNS records, DKIM, domains and email addresses, read 18 November 2026.