Guides
SendGrid domain authentication for DMARC
11 November 2026
To authenticate a domain in SendGrid, go to Settings, Sender Authentication, and start Domain Authentication. With automated security on, which is the default, SendGrid gives you CNAME records that point to records it maintains, plus a TXT record for DMARC. Publish them, verify, and SendGrid signs your mail with DKIM on your domain and uses a return path on your domain, so DMARC can pass. Without this step, mail sent through SendGrid passes checks on SendGrid’s domain, not yours.
These notes follow Twilio’s domain authentication guide, checked in November 2026. After you publish the records, a $129 Snapshot can confirm the whole domain, SendGrid and every other sender, from public DNS.
Why it matters for DMARC
DMARC passes when SPF or DKIM passes on a domain that matches your From address. A SendGrid account that has not authenticated your domain sends with SendGrid’s own domains in the places receivers check. The message may show spf=pass and dkim=pass in the headers, but for the wrong domain, so DMARC fails. That is what Gmail’s 4.7.32 bounce means: the From header is not aligned. Our guide to why DMARC fails explains alignment.
Domain authentication fixes both halves. DKIM is signed with your domain, and the return path, which SPF checks, becomes a subdomain of yours.
Start the setup
- In SendGrid, go to Settings, then Sender Authentication.
- In the Domain Authentication section, click Get Started.
- Enter your root domain, without
wwwor other subdomains. Twilio’s guide says to omit subdomains here. - Choose whether to use automated security, and whether to set a custom return path or link branding.
- SendGrid shows the Install DNS Records page with the records to add.
Automated security on (the default)
Twilio says automated security defaults to on. SendGrid then creates and maintains the SPF, DKIM, and DMARC details for you, and you publish records that point to them. The Install DNS Records page shows four records:
- One CNAME that points your branded subdomain to SendGrid. This one supports SPF and DKIM.
- Two CNAMEs for link branding, which route click and open tracking.
- One TXT record with a DMARC policy.
The exact host names and values are generated for your account. Copy them from the page. Because they are CNAMEs, SendGrid can rotate keys or change IP ranges without you editing DNS again.
Twilio notes one limit: if your DNS provider does not accept underscores in CNAME records, you cannot use automated security.
The DMARC TXT record
If your domain already has a DMARC record, do not add a second one. One _dmarc record covers every sender on the domain. Two records on the same name break DMARC. Keep yours, and make sure it has an rua address so you can see SendGrid’s results in the reports. If you do not have one yet, start with the record SendGrid suggests or with p=none and reports, then tighten later. See DMARC record tags.
Automated security off
With automated security off, Twilio says you add MX and TXT records yourself and keep them up to date. SendGrid provides the values for the MX server and the SPF, DKIM, and DMARC records.
The trade-off is upkeep. If SendGrid changes a key or a range, you edit DNS. Choose this only if your DNS host cannot do underscores in CNAMEs, or if you have a reason to hold the records yourself.
If you add SPF details for SendGrid by hand on a name that already has an SPF record, merge them into one record. Two SPF records on the same name is a PermError. See SPF PermError.
Custom return path
Twilio says SendGrid creates a four-character subdomain by default for bounces and unsubscribes. That subdomain is the return path, the address SPF checks. You can choose your own alphanumeric label instead. It appears as a CNAME pointing to sendgrid.net.
Twilio gives a warning worth repeating: if the label you choose matches a record you already have, the new CNAME overwrites it and breaks that name. Check your existing records before picking a label.
Link branding
Link branding makes tracked links use a subdomain of yours instead of sendgrid.net. Twilio says it generates random subdomains by default, lets you choose your own, and can provision an SSL certificate for those links. It is not part of SPF, DKIM, or DMARC, but links on a domain you own look more consistent to readers.
Twilio says link branding, and EU-pinned domains, require the Email API Pro plan or higher, or the Marketing Campaigns Advanced plan or higher.
Entering the records
Twilio’s guide calls out a mistake that catches people at GoDaddy, Amazon Route 53, and Namecheap: these hosts add your domain to the name you type. If SendGrid shows em123.example.com, enter only em123. Typing the full name gives you em123.example.com.example.com, which fails verification.
If you use Cloudflare, set the CNAMEs to DNS only, not proxied. A proxied CNAME answers with Cloudflare’s addresses, so receivers never reach SendGrid’s records. Our guide to adding a DKIM record covers both hosts.
Verify
Click Verify on the Install DNS Records page once the records are published. Twilio says DNS changes can take up to 48 hours. If verification fails, wait and retry after 48 hours, and contact SendGrid support if it still fails after that.
You can check the records yourself first:
dig CNAME em123.example.com +short
Use the host names SendGrid gave you. Each should return a SendGrid target.
Test a real message
Send a message through SendGrid to a Gmail address and use Show original. You want:
spf=passwithsmtp.mailfromon your return-path subdomain.dkim=passwithheader.dorheader.ion your domain.dmarc=pass.
If DKIM still shows a SendGrid domain, the message was sent from a From address on a domain you have not authenticated. Our guide to reading email headers walks through each line.
Common problems
- Domain doubled in the host name. Enter only the part SendGrid shows before your domain.
- Return path label clashes with an existing record. Pick a label nobody uses.
- A second DMARC record. Keep one.
- Authenticated the root, sending from a subdomain. Authenticate the domain you put in the From address, or check that relaxed alignment covers it.
- Old SPF include left behind. With automated security, you usually do not need a SendGrid include in your root SPF record. Extra includes only use up your ten-lookup budget.
Sources
- Twilio SendGrid: How to set up domain authentication (checked November 2026: automated security, records, return path, link branding, plans, host names, 48 hours)
- Google Workspace: Gmail SMTP errors and codes (4.7.32)
- RFC 7208: SPF, RFC 6376: DKIM, RFC 9989: DMARC