
Checking a DKIM record means asking DNS for the public key that receivers will use, then reading that TXT like a checklist. It does not mean a campaign landed in the inbox, and it does not mean the last message was signed. Those are different tests.
This article is the DNS half. Pair it with how to find your DKIM selector and the DKIM record checker. For the protocol itself, see DKIM explained.
Direct answer
- Get
s=andd=from a receivedDKIM-Signatureheader. - Query TXT at
s._domainkey.d. - Expect
v=DKIM1and ap=tag. - If nothing is returned, the selector is wrong, the record has not propagated, or that name was never published.
- If
p=is empty, the selector is revoked on purpose. - Confirm a live message separately (
Authentication-Resultsor Gmail “Show original”).
What “checking DKIM” is not
People use the phrase for three jobs:
| Job | What you inspect |
|---|---|
| Is the public key published? | DNS TXT at selector._domainkey.domain |
| Did this message verify? | Received headers / provider auth panel |
| Will DMARC pass? | Alignment of d= with the From domain, plus SPF or DKIM |
This guide is the first job. Mixing them produces false confidence (“the TXT exists, so Gmail will inbox this”) or false panic (“dig failed, so all mail is broken” when you queried the wrong selector).
Build the lookup name carefully
Rules that prevent most failures:
- Lowercase is conventional; DNS names are case insensitive for this purpose.
- Do not add
https://or a path. - Do not look up the apex unless the selector is literally on the apex (it is not).
- Use the signing domain from
d=, not the website domain you assume.
news.example.com and example.com are different names. A record on one does not cover the other.
If your DNS host shows a CNAME at selector._domainkey.example.com, that is still a valid publication pattern. Public resolvers follow the CNAME and return TXT. A checker that reports “no TXT” after a CNAME usually queried a different name or a resolver that has not seen the change yet.
Read the TXT like a tagged list
DKIM key records are semicolon-separated tags.
Required in practice:
v=DKIM1— record type. Otherv=values are not a standard public key record.p=— Base64 public key, or empty to revoke.
Common optional tags:
k=—rsa(default) ored25519.n=— notes for humans. Receivers ignore it.t=y— testing mode. Some receivers treat failures more gently. Do not leave this on for production.t=s— restrictsi=to the same domain asd=.s=— service type. Rarely needed for campaign mail.h=— acceptable hash algorithms.
Whitespace inside p= is allowed; receivers strip it. Other characters are not. Long keys are often stored as multiple quoted strings in one TXT record. A correct resolver concatenates them. If you copy only the first string from a control panel, the key looks truncated.
Interpret the four usual outcomes
No record. Wrong selector, typo in the domain, or DNS not propagated. TTL on DKIM records is often 300–3600 seconds, but some hosts cache longer. Wait, then query a public resolver, not only the DNS host’s internal preview.
Record present, p= empty. Intentional revocation. Good during rotation after the new selector is live. Bad if this is still the selector in production signatures.
Record present, v or p malformed. Copy/paste errors, a SPF record published at the DKIM name, or a truncated key. Fix the TXT; do not “warm” volume hoping it heals.
Record looks fine. Syntax passed. Next: send a test and read dkim=pass (or fail) on the received message. Then check whether d= aligns with From for DMARC.
Gmail still wants RSA keys of at least 1024 bits and recommends 2048. A very short p= value is a warning even if Base64 parses.
Browser, dig, and control panel
Browser checker: Paste domain and selector. You get the concatenated TXT, parsed tags, and plain-language issues. It uses DNS over HTTPS from your machine. It does not log into your DNS host and does not verify b= on a message.
dig / nslookup:
dig TXT google._domainkey.example.com +short
Use a name you actually observed. +trace is only needed when you suspect a delegation problem.
Control panel: Confirm the host name is selector._domainkey and the type is TXT or CNAME as the vendor specified. Some UIs hide the _domainkey label in a subdomain field. Double-check the FQDN the panel will publish.
Do not paste private keys into any of these tools. If a vendor screen asks for a public key you generate yourself, that is a different workflow (you run the signer). Most campaign tools generate the pair and only ask you to publish DNS.
Check more than one selector
During rotation you should see two working names. After rotation, the old p= should go empty, then the record can be deleted once queued mail is gone.
Multiple ESPs mean multiple selectors forever. Checking only the newsletter key will not explain a failed receipt from the product app.
Keep a table:
- Product
- Selector
- DNS name
- Last verified date
- Last received
dkim=pass
When a report says DKIM failed, you will know which row to open.
What a pass in Gmail actually said
Gmail’s “SPF: PASS” and “DKIM: PASS” lines describe that message. They can pass while:
- Another campaign stream is unsigned
- DMARC fails because
d=is a parent vendor domain - The message still lands in spam for reputation or complaint reasons
So: DNS check, then message check, then placement check. For placement, use why emails go to spam and email deliverability. Do not “fix DKIM” for a complaint problem.
A short verification script you can reuse
- Send to a mailbox you control, through the production route.
- Copy
s=andd=. - Run the DKIM record checker.
- Confirm
v=DKIM1and a non-emptyp=. - Confirm the original message shows DKIM pass.
- Confirm
d=is aligned if you need DMARC. - Write the date next to that selector.
That is enough for a weekly ops check. You do not need a new SaaS dashboard for the DNS half.
Checking after a provider change
Migrations are when records rot. You add a new ESP’s CNAME, forget the old selector, and a forgotten product still signs with it—or the reverse.
On cutover day:
- Publish the new selector first. Do not delete the old key yet.
- Send one message through the new SMTP/API user. Confirm
s=matches the new name. - Keep the old TXT until queued mail and retries drain (often 48 hours; longer if you have slow jobs).
- Empty
p=on the old selector, wait, then delete the name if you want a tidy zone.
If a regional office still uses Google Workspace while marketing uses an ESP, you will have two healthy records forever. That is normal. Document both.
TTL mistakes: a 24-hour TTL on a key you are about to revoke leaves receivers with the old p= after you think you rotated. Lower TTL a day before rotation, then raise it again when the new key is boring.
Related reading
- How to find your DKIM selector and public key
- DKIM vs SPF vs DMARC
- How to add a BIMI logo (only after DMARC is enforced)