Microsoft 365 Error Codes

Fix Microsoft 365 TXT Record Errors on an onmicrosoft.com Domain

Kushani NimanthikaKushani Nimanthika Nov 20, 2026 869 views

Question details

The user needs to add a custom TXT record for Mimecast validation to an onmicrosoft.com domain.

Fix Microsoft 365 TXT Record Errors on an onmicrosoft.com Domain
Product
Microsoft 365 admin center
Device & OS
not provided
Scenario
An administrator is adding a Mimecast validation record to the organization's initial Microsoft domain.
Observed behavior
The admin portal displays the error: "You cannot edit or remove the Office 365 SPF record."
Before you start

Have the TXT record name and value supplied by Mimecast ready, and confirm which domain Mimecast requires you to validate. Sign in with an account that has permission to manage domains in the Microsoft 365 admin center.

Solution 1Recommended

Sign in again and retry the custom TXT record

Use this approach if the error resulted from the previously reported temporary Microsoft 365 admin portal issue.

Microsoft corrected a temporary portal issue that prevented custom TXT records from being added to the initial domain. Do not edit or remove the protected Office 365 SPF record as a workaround.

1
Sign in again

Sign out of the Microsoft 365 admin center, then sign back in with your administrator account.

2
Open the domain settings

In the admin center, go to Settings > Domains and select the affected onmicrosoft.com domain.

3
Add the validation record

Open the DNS records section and, if the option is available, choose Add record. Select TXT and enter the name and value supplied by Mimecast.

4
Save and verify

Save the new record, then return to Mimecast and retry its domain validation after the record has had time to propagate.

Sign in again and retry the custom TXT record
Keep the SPF record unchanged: The Mimecast validation record is a separate TXT record. Do not replace or delete the protected Office 365 SPF record.
Free Microsoft Office alternative

Use WPS Office for Everyday Document Work

WPS Office is a free, lightweight alternative with a familiar interface for working with Microsoft Office files and moving existing documents into your workflow. Microsoft 365 domain and DNS settings must still be managed through Microsoft.

Work with documents, spreadsheets, and presentations in a familiar interfaceOpen and edit Microsoft Office formats, including DOCX, XLSX, and PPTXUse a lightweight office suite while managing Microsoft 365 domain issues separately
microsoft office alternative - wps office

Frequently Asked Questions

Why does an SPF error appear when I add a Mimecast TXT record?

A temporary Microsoft 365 admin portal issue previously caused this error when administrators added custom TXT records to the initial domain. Sign out and back in, then retry under Settings > Domains.

Should I change the Office 365 SPF record to complete validation?

No. The protected Office 365 SPF record should not be edited or removed to add a separate Mimecast validation TXT record.

What should I do if the error continues?

Check Health > Service health in the Microsoft 365 admin center, then use Help & support to report the error and the record you need to add.

How do I know which domain to validate in Mimecast?

Review the domain and TXT record details in your Mimecast validation instructions. If they are unclear, contact Mimecast Support before adding the record.