What is a DNS TXT Record?
A **TXT (Text)** record is a versatile type of DNS record that allows domain administrators to store arbitrary text-based information. Originally intended for human-readable notes, its flexibility has made it essential for a wide range of machine-readable data, particularly for email security and domain ownership verification.
Common Uses for TXT Records
While a TXT record can hold any text, it is most commonly used for:
- Sender Policy Framework (SPF): An SPF record, stored as a TXT record, lists the mail servers that are authorized to send email on behalf of your domain. This helps prevent email spoofing. Example:
"v=spf1 include:_spf.google.com ~all"
- DomainKeys Identified Mail (DKIM): DKIM uses a TXT record to store a public key. Receiving mail servers use this key to verify that an email was actually sent by an authorized server and that its content hasn't been tampered with.
- Domain-based Message Authentication, Reporting, and Conformance (DMARC): A DMARC record, also a TXT record, tells receiving servers how to handle emails that fail SPF or DKIM checks and where to send reports.
- Domain Ownership Verification: Services like Google Search Console, Microsoft 365, and others often require you to add a unique TXT record to your DNS to prove you own and control the domain.
TXT Record Format
The structure of a TXT record is straightforward:
[Domain Name] [TTL] IN TXT "[Text Content]"
- Domain Name: The hostname the record applies to (e.g.,
example.com
or a specific subdomain like _dmarc.example.com
).
- TTL (Time To Live): The caching duration in seconds.
- IN: Stands for Internet.
- TXT: Specifies that this is a Text record.
- Text Content: The actual text string, enclosed in double quotes. A single record can contain multiple strings, and the maximum length of a single string is 255 characters.
Our tool queries for all TXT records at the domain you specify and displays their content, allowing you to easily check your configurations.