Skip to content

Menu

DKIM Record Generator

Generate DKIM DNS records

Runs entirely in your browserEmail & ValidationFree, no sign-up
Loading tool

01What is DKIM Record Generator?

DKIM, defined in RFC 6376, lets a receiving mail server check a signature on your messages against a public key you publish in DNS. Setting it up by hand means running openssl, stripping PEM headers and pasting a long string into a DNS panel without breaking it. This generator does those steps in one page. When the page loads, or when you change the Key Size, it asks your browser's Web Crypto API for a fresh RSA key pair. The public exponent is 65537 and the size is 1024 or 2048 bits. The public key is exported as base64 SubjectPublicKeyInfo, which is the format the p= tag expects and the same thing openssl rsa -pubout gives you between its header lines. You enter a Domain and a Selector. The DNS Name box shows where the record lives, in the selector._domainkey.domain form. Input is lowercased and a trailing dot is dropped, so "Example.com." with selector "Google" gives google._domainkey.example.com. The TXT Record Value starts with v=DKIM1; k=rsa, adds t=y when Test mode is ticked, and ends with p= and the key. Here is a concrete run. A 2048-bit key produced a 392-character p= value and a 410-character record. A single DNS TXT string can hold only 255 characters, so the Full DNS Record panel split it into two quoted strings on one zone-file line. A 1024-bit key with t=y came to 239 characters and fit in one string. Resolvers join split strings back together, so the signature check still sees one value. The private key appears as a PKCS#8 PEM block that starts with BEGIN PRIVATE KEY. OpenDKIM, Rspamd and most signing libraries read that format. The Hash label reads rsa-sha256, because RFC 8301 dropped rsa-sha1 for DKIM signing. The keys are created and held in this browser tab only. No server sees them. That also means they vanish when you leave or click New key pair, so copy the private key before anything else. Web Crypto needs a secure https page, and the tool shows an error if key generation fails. A few limits are worth stating plainly. Only RSA is offered, not Ed25519 from RFC 8463. There is no DNS lookup to confirm your record went live. If Google Workspace, Microsoft 365 or your email service generates DKIM keys for you, publish their value instead.

Sysadmins and DevOps engineers running their own mail servers who need a DKIM key pair and a correctly named TXT record without touching openssl. The tool runs entirely in your browser, so your data never leaves your device.

02How to use DKIM Record Generator

  1. Enter your Domain and a Selector such as mail or s2026.
  2. Pick a Key Size. 2048-bit is selected by default, and a new key pair is generated as soon as you change it.
  3. Tick Test mode (t=y) while you are still checking that signatures verify.
  4. Copy the private key from the Private Key panel and install it on your mail server or signing service first.
  5. Click Copy Record and publish it as a TXT record at the DNS Name shown, or paste the Full DNS Record line into a zone file.
  6. Send a test message and look for dkim=pass in the Authentication-Results header.

03Worked examples

Input: Domain Example.com., Selector Google, 2048-bit, Test mode off
Result: DNS Name: google._domainkey.example.com v=DKIM1; k=rsa; p=MIIBIjANBgkqhkiG9w0BAQ…
Trimmed. The key is random on every run. In our run the p= value was 392 characters and the full record 410, so the zone-file line held two quoted strings.
Input: Domain example.com, Selector mail, 1024-bit, Test mode on
Result: DNS Name: mail._domainkey.example.com v=DKIM1; k=rsa; t=y; p=MIGfMA0GCSqGSIb3D…
Trimmed. A 1024-bit record was 239 characters, short enough for a single TXT string.
Input: Domain example.com, Selector s2026.mktg, 2048-bit, Test mode on
Result: DNS Name: s2026.mktg._domainkey.example.com
Selectors may contain dots between labels, which is handy for grouping keys by service.
Input: Any settings, Private Key panel
Result: -----BEGIN PRIVATE KEY----- MIIEv… -----END PRIVATE KEY-----
Trimmed. A PKCS#8 PEM block wrapped at 64 characters per line. A 2048-bit key ran to 28 lines including the header and footer.

04Common use cases

  • Creating a DKIM key pair and record for a self-hosted Postfix and OpenDKIM server without running openssl by hand
  • Working out the exact host name to type into Cloudflare or Route 53 for a selector such as s2026
  • Making a throwaway key pair for a staging mail server, with t=y set so receivers know it is a test
  • Rotating a key by publishing a new selector alongside the old one before switching the signer over
  • Getting the split, quoted zone-file form of a 2048-bit record for a BIND or NSD zone file
  • Showing a colleague how separate selectors let a newsletter tool and a CRM sign for the same domain

05Tips

  • Some DNS panels want the long value pasted as one string and split it themselves. Others want the quoted pieces from the Full DNS Record panel. Check which yours expects before saving.
  • Treat the private key like a password. Anyone holding it can sign mail as your domain, so keep it out of tickets and chat.
  • Use a date-based selector such as s2026. When you rotate, the new key gets a new selector and the old record can stay until in-flight mail is delivered.
  • Remove t=y once signatures verify. Under RFC 6376, verifiers must not treat test-mode signed mail differently from unsigned mail, so the flag gives up the benefit of DKIM.
  • RFC 8301 recommends 2048-bit keys. Pick 1024 only if a DNS host truly cannot store the longer record.

06Related concepts

DKIM, DNS TXT record, Email authentication, DKIM selector, RSA public key, DMARC.

Frequently Asked Questions

What is DKIM Record Generator?

DKIM Record Generator is a free, browser-based developer tool on AIDToolStack. Generate DKIM DNS records It requires no installation or sign-up and works entirely in your browser.

Is DKIM Record Generator free to use?

Yes. No sign-up, no fees and no usage cap.

Does DKIM Record Generator store my data?

No. It runs in your browser; nothing is uploaded.

Cheat sheet

Reviews and commentsShow

Reviews

Sign in to leave a review.

Loading reviews…

Comments

Sign in to leave a comment.

Loading comments…

What changed in AI dev tools, once a month

Renames, shutdowns, pricing changes and new MCP setups, each with a source.

Subscribe