TXT records are DNS records that store text-based information for a domain or subdomain. They are widely used for domain verification, email authentication and service validation. Although a TXT record does not normally direct website traffic like an A record or route email like an MX record, it is still one of the most important DNS record types because many modern services depend on it.
For Apexhost customers, TXT records are commonly used when setting up Microsoft 365, Google Workspace, SPF, DKIM, DMARC, SSL validation and third-party domain verification. Understanding what a TXT record does can help you make DNS changes more confidently and avoid service setup problems.
What a TXT record does
DNS, or Domain Name System, works like a directory for internet services. Some DNS records point traffic to a destination, while others provide instructions or verification data. A TXT record belongs to the second group. It stores a text value that other systems can read when checking whether a domain is configured correctly.
For example, a provider may ask you to add a TXT record to prove that you own a domain. Email services may also use TXT records to publish policies that help receiving servers decide whether a message is legitimate.
In simple terms, a TXT record lets a domain publish text information that other internet services can check and use.
Common uses for TXT records
TXT records are used in many common DNS scenarios, including:
* Verifying domain ownership for Microsoft 365, Google Workspace and other third-party services
* Publishing an SPF record to help identify which mail servers are allowed to send email for your domain
* Publishing a DKIM key so receiving mail servers can validate signed outgoing email
* Publishing a DMARC policy to help protect the domain from spoofing and phishing
* Completing DNS-based validation for some SSL certificate or security services
* Storing service-specific text values required by external platforms
Because TXT records often support security and verification, they should be entered exactly as supplied by the service provider. Even a small mistake can cause validation or email delivery problems.
How TXT records are structured
A TXT record usually contains the following parts:
* Name / Host — the domain or subdomain where the record applies, such as @, a blank host field, or a selector like default._domainkey
* Type — TXT
* Value / Text — the text string provided by the service you are configuring
* TTL — Time To Live, which controls how long resolvers may cache the record before checking again
The exact field names vary between DNS platforms, but the purpose is the same. In many DNS editors, @ represents the root domain, also called the apex domain.
Examples of TXT record values include:
* Domain verification text such as MS=ms12345678
* SPF text such as v=spf1 include:spf.protection.outlook.com -all
* A service validation string provided by a third-party platform
Some TXT values are short, while others can be longer and more technical. Always copy the record exactly as instructed.
TXT records and email security
TXT records play an important role in modern email configuration. If your domain sends or receives business email, TXT records may be required to improve trust, reduce spoofing and support message delivery.
The most common email-related TXT record uses include:
* SPF, which tells other mail servers which systems are allowed to send email for your domain
* DKIM, which publishes a public key used to verify signed outgoing messages
* DMARC, which tells receiving servers how to handle messages that fail authentication checks
These records work together with MX records and your email platform settings. If they are missing or incorrect, outgoing mail may be marked as spam, rejected or more vulnerable to impersonation.
If you are configuring business email, it is important to understand that website DNS records and email DNS records are separate. A website change does not normally update email protection records automatically.
When you would use a TXT record
You may need to add or update a TXT record when:
* Connecting a domain to Microsoft 365
* Setting up Google Workspace
* Verifying a domain with a third-party website or cloud service
* Publishing or updating SPF, DKIM or DMARC settings
* Completing DNS-based SSL or security verification
* Following instructions provided by Apexhost Support or another service provider
Before changing a TXT record, make sure you know which DNS service is authoritative for the domain. Updating DNS in the wrong control panel will not affect the live domain.
Best practices for managing TXT records
* Use the exact host name and value supplied by the provider
* Check whether an existing TXT record already serves the same purpose before adding another one
* Be careful with SPF records, because having multiple SPF TXT records for the same host can cause problems
* Allow time for DNS propagation after saving the change
* Keep a record of why the TXT entry was added, especially for third-party verifications
* Review old verification records occasionally and remove only those you are certain are no longer required
TXT records are simple in structure but can be critical in effect. A small typo, missing character or duplicate policy may prevent a service from working correctly.
Troubleshooting TXT record issues
The TXT record does not appear in DNS lookups
This is often caused by DNS propagation delay, saving the record in the wrong DNS provider, or entering the host name incorrectly.
Check which name servers are active for the domain, confirm that the change was made in the authoritative DNS zone and allow time for caches to refresh.
Domain verification is failing
This usually means the TXT value does not exactly match what the provider expects, or the record was added to the wrong host name.
Recheck the supplied value, confirm whether the record should be added at the root domain or a specific subdomain, and make sure there are no missing characters or extra spaces.
Email authentication is still failing after adding SPF, DKIM or DMARC
This may be caused by an incorrect value, multiple conflicting TXT records, or incomplete configuration in the email platform itself.
Review the record carefully and confirm that the corresponding email service settings are also complete. For SPF in particular, make sure there is only one SPF record for the same host name unless a provider specifically documents otherwise.
Frequently asked questions
What is a TXT record used for?
A TXT record is used to publish text information in DNS. Common uses include domain verification, SPF, DKIM, DMARC and security-related validation.
Does a TXT record affect my website?
Not usually in a direct way. TXT records do not normally control where a website loads from, but they can affect related services such as email authentication, SSL validation or third-party integrations.
Can I have more than one TXT record?
Yes. A domain can have multiple TXT records, often for different purposes. However, some record types such as SPF require extra care to avoid conflicts.
How long do TXT record changes take?
Changes are usually saved immediately on the authoritative DNS server, but other systems may continue using cached results for a period of time based on TTL and resolver behaviour.
What is the difference between a TXT record and an MX record?
A TXT record stores text information for verification or policy purposes. An MX record tells other mail servers where to deliver incoming email for the domain.
Related Articles
-
What is DNS? (DNS)
-
A Records (DNS Records)
-
AAAA Records (DNS Records)
-
MX Records (DNS Records)
-
How to create DNS records (SRV etc) for office 365
-
Domain Troubleshooting (Domains)
Need More Help?
If you require further assistance, please contact Apexhost Support at support@apexhost.com.au.
