Free tool · Email auth
DKIM TXT record generator
Paste the public key your mail provider gave you and get the DKIM TXT record properly formatted with v=DKIM1, k=, h=, p= tags in the right order. Includes the host name (selector._domainkey.domain) and a multi-string split for DNS consoles that don't auto-handle long values.
Short label your mail platform uses to find this key. Each rotation gets a new selector (e.g. 2026q1).
The apex (or subdomain) you sign mail with.
Generated inside your mail platform (Google Workspace, M365, SendGrid, Mailgun, etc.). Do NOT paste a private key here - this tool stays in your browser but private keys never leave the mail platform that generated them.
What this tool checks
What this tool does NOT do: generate the keypair. The DKIM private key has to live with the mail platform that signs your outbound mail; generating it in a browser and copy-pasting it across systems is fragile and unsafe. Generate the keypair inside Google Workspace Admin / M365 Exchange Admin / SendGrid / Mailgun / etc. - those tools emit the public key for you to publish.
What this tool DOES do: take the public key those tools handed you (usually as a chunk of base64 sometimes wrapped in -----BEGIN PUBLIC KEY----- markers) and format it as a syntactically-correct DKIM TXT record. Right v= prefix, right tag order, right handling of the 255-character DNS TXT string cap.
Selector strategy: use one selector per sending platform AND rotate at least yearly. A typical year of records looks like google2026q1._domainkey, sendgrid2026._domainkey, mailgun2026q1._domainkey. New selector for a new key means you can stage the rotation, dual-sign with old + new for a week, then retire the old.