How to Add a DKIM Record
DKIM setup is a copy-precision exercise: your sending service hands you a selector and a public key, you publish them as a TXT record at selector._domainkey, you verify. Here is the whole procedure with the failure points marked.
DKIM record fields
| Field | Example value | Meaning |
|---|---|---|
| Host / Name | s1._domainkey | Selector plus the fixed _domainkey label |
| Type | TXT | DKIM keys publish as TXT (some hosts use CNAME) |
| Value | v=DKIM1; k=rsa; p=MIIB... | The public key, verbatim from your provider |
| TTL | 3600 | Standard caching |
Step by step
- Get the values from your sender. Google Workspace, Microsoft 365, and every ESP generate the key pair and show you: the selector (host name fragment), and the TXT value starting
v=DKIM1; k=rsa; p=.... - Create the TXT record in your DNS host. Host/name:
selector._domainkey(your provider may show the fullselector._domainkey.yourdomain.com). Value: the key string verbatim. TTL 3600. - Do not touch the key. No added spaces, no smart quotes, no truncation. If the value exceeds 255 characters your DNS host either splits it automatically or expects multiple quoted strings.
- Activate signing on the sender side. Publishing DNS does nothing until the service starts signing; in Google Workspace you must click "Start authentication", in M365 run Enable-DkimSigning.
- Verify end to end. The DKIM checker confirms the key resolves and reports its strength; then send yourself a message and check the
DKIM-Signatureheader plus the receiver'sAuthentication-Results.
Common failure points
- Host written as
_domainkeyalone, dropping the selector: wrong name, no resolution. - Key pasted with the quotes some panels add automatically, doubling them.
- DNS published but sender-side signing never enabled: everything checks out except actual mail.
- Multiple senders sharing one selector: they must each use their own.
Frequently asked questions
Where do I get my DKIM key?+
From your sending service: Gmail, Microsoft 365, and ESPs generate the key pair and show you the public value to publish. The private key never leaves their system in hosted setups.
Can I add DKIM without my ESP?+
Only if you run your own mail server and generate the key pair yourself. Hosted ESPs own the private key and publish the selector for you to add.
How do I test the record after adding it?+
Send a message and read the DKIM result in its headers, or run the selector through our DKIM record checker before sending anything.
Related
Last verified: 2026-10-28