How do I add a TXT record to a DNS configuration for Google Postmaster?
Michael Ko
Co-founder & CEO, Suped
Published 16 Apr 2025
Updated 15 Aug 2025
8 min read
Setting up Google Postmaster Tools is a crucial step for anyone serious about email deliverability. This powerful tool provides insights into your sending reputation, spam rates, delivery errors, and DMARC authentication failures. To gain access to these valuable insights for your domain, the primary method of verification involves adding a TXT record to your DNS configuration.
I often see marketers and email administrators encounter challenges when trying to locate where to add this TXT record. Domain management can be complex, with various registrars, hosting providers, and third-party DNS services all playing a role. Understanding where your domain's DNS is actually managed is the first hurdle in this process. Once you pinpoint the correct platform, adding the record is usually straightforward.
The good news is that adding a TXT record is a standard DNS operation, and the steps are generally similar across most providers. My goal here is to guide you through the entire process, from identifying your DNS host to successfully verifying your domain in Google Postmaster Tools. We'll cover what a TXT record is, how to get the specific value from Google, and the exact steps to add it without disrupting your existing email or website functionality. This will empower you to monitor and improve your email performance effectively.
Finding your DNS provider
Before you can add any record, you need to know where your domain's DNS records are managed. This isn't always where you registered your domain, as many users opt for third-party DNS management services like Cloudflare or their web hosting provider's DNS. If you're unsure, there are a couple of ways to find this information.
The most common scenario is that your DNS is managed by your domain registrar (e.g., GoDaddy, Namecheap) or your web hosting provider (e.g., Shopify, Bluehost). Start by logging into these accounts and looking for sections related to DNS Management, DNS Zone Editor, or Advanced DNS. If you've recently migrated your site or services, double-check if your DNS name servers were updated to point to a new provider. You can read more about setting up DNS records for various providers.
If you're still unsure, you can perform a WHOIS lookup or use a DNS lookup tool. These tools will show you the name servers your domain is currently using, which points to the provider managing your DNS. For example, if it lists name servers like ns1.godaddy.com and ns2.godaddy.com, then GoDaddy is your DNS host. I recommend using a trusted DNS lookup tool for this.
Example DNS Name Server Lookupbash
dig NS yourdomain.com
Generating the TXT record
Once you've identified your DNS provider, the next step is to obtain the specific TXT record value from Google Postmaster Tools. This is a unique string that Google generates to verify that you own the domain you're trying to add.
To get this value, go to Google Postmaster Tools and sign in with the Google account you wish to associate with your Postmaster Tools access. Click on the Add a domain button, enter your domain name, and click Next. Google will then present you with a verification method, and the recommended option is usually a TXT record. Copy the entire string provided, which will look something like google-site-verification=xxxxxxxxxxxxxxxxx.
This unique string is what verifies your ownership. It's important to copy it precisely, without any extra spaces or characters, as even a small typo can prevent verification. This record does not affect your website or email functionality; it simply serves as a digital signature proving you control the domain.
Example Google Postmaster Tools TXT record
When Google Postmaster Tools asks you to verify your domain, it will provide a specific string. This string is what you'll use for the TXT record's value. It typically starts with google-site-verification= followed by a unique alphanumeric code. You will paste this entire string into the Value or Content field of your TXT record.
Now that you have your TXT record string and know where your DNS is managed, it's time to add the record. The interface will vary slightly depending on your provider, but the core steps remain consistent. Look for a section like Add Record or Create New Record.
When adding the record, you'll typically encounter three key fields: Type, Host/Name, and Value/Content. For Type, select TXT. For Host/Name, you'll typically enter @ or leave it blank to apply the record to your root domain. If you're adding a subdomain, you'll enter the subdomain name (e.g., mail for mail.yourdomain.com). Remember, for Google Postmaster, it's generally recommended to verify the root domain if you send email from it directly. You can find more details on how to set up Postmaster Tools for subdomains.
For the Value/Content field, paste the full TXT record string you copied from Google Postmaster Tools. It's crucial not to alter this string in any way. Also, be careful not to replace any existing TXT records, especially if they are for SPF (Sender Policy Framework) or DMARC (Domain-based Message Authentication, Reporting, and Conformance). Multiple TXT records can coexist as long as they serve different purposes or are correctly formatted. This is particularly relevant if you're also working on aligning SPF authentication or troubleshooting DMARC verification failures. After entering the information, save the record. DNS changes can take some time to propagate across the internet, typically from a few minutes to several hours.
DNS provider
Typical location
Host/Name field for root domain
Value/Content field
Cloudflare
DNS app in dashboard
@
google-site-verification=...
GoDaddy
DNS management page
@
google-site-verification=...
Namecheap
Advanced DNS tab
@
google-site-verification=...
Verifying your domain and troubleshooting
After adding the TXT record, return to Google Postmaster Tools and click the Verify button. Keep in mind that DNS propagation can take some time. While it's often within minutes, it can sometimes take up to 48 hours for changes to fully update across all DNS servers globally. If verification doesn't happen immediately, give it some time before trying again. This delay is normal and expected.
If you encounter issues, such as the domain not verifying after a reasonable propagation period, double-check your TXT record. Common mistakes include typos, incorrect host entries (e.g., using www instead of @ for the root domain), or having conflicting records. You can use a free email deliverability tester to diagnose DNS issues related to email. Remember, for Postmaster Tools, the TXT record is for domain ownership verification, not for sending email, so it won't impact your sending paths.
Successfully verifying your domain in Google Postmaster Tools unlocks critical insights for optimizing your email program. It helps you identify if your emails are landing in the spam folder, if you're on any blacklists (or blocklists), and how your domain's reputation is perceived by Gmail. This data is invaluable for maintaining high email deliverability. Consider reviewing how to improve domain reputation using these tools.
Common issues
Propagation delay: DNS changes can take up to 48 hours to update globally.
Incorrect host entry: Using www or leaving it blank when it requires @, or vice versa.
Typographical errors: Any small mistake in the copied TXT value will cause verification to fail.
Conflicting records: Accidentally overwriting an existing record or having multiple, improperly configured records.
Solutions
Wait it out: Allow sufficient time for DNS changes to propagate before re-attempting verification.
Check host field: Ensure you're using the correct host entry, typically @ for the root domain.
Verify TXT value: Copy and paste the TXT record directly from Google to avoid errors.
Avoid overwriting: Always add new records instead of modifying existing ones unless you know their purpose.
Views from the trenches
Best practices
Always identify the correct DNS provider before making any changes to prevent disruptions.
Use a DNS lookup tool to confirm name servers if you are unsure who hosts your DNS.
Copy the Google Postmaster Tools TXT record exactly to avoid validation errors, including all characters.
Common pitfalls
Attempting to add the TXT record at the wrong DNS provider (e.g., domain registrar instead of hosting provider).
Typographical errors or extra spaces in the TXT record value can lead to failed verification.
Incorrectly setting the 'Host' or 'Name' field (e.g., using 'www' when '@' or blank is required for the root domain).
Expert tips
Check Google Postmaster Tools for any specific instructions as they can sometimes vary or be updated.
Keep records of all DNS changes you make, including dates and specific values for future reference.
Verify both root domains and subdomains that send email to get comprehensive data in Postmaster Tools.
Marketer view
Marketer from Email Geeks says that determining where a client's domain is registered is the first step in adding any DNS record.
2021-02-20 - Email Geeks
Marketer view
Marketer from Email Geeks says the TXT record should be placed at the domain root, often represented by an @ symbol in DNS dashboards.
2021-02-20 - Email Geeks
Key takeaways for Postmaster Tools setup
Adding a TXT record for Google Postmaster Tools is a fundamental step in taking control of your email deliverability. While it might seem technical initially, breaking it down into identifying your DNS provider, obtaining the record, and then carefully adding it makes the process manageable. This verification ensures you gain access to vital data on your sending domain's performance, allowing you to proactively address potential issues.
By following these steps, you'll not only verify your domain but also lay the groundwork for a more robust and effective email program. Remember to be patient with DNS propagation and meticulous with the record values. Once verified, you'll be equipped with the insights needed to maintain a healthy sender reputation and ensure your emails reach the inbox.