Email & Deliverability4 min read

How to Rotate DKIM Selectors and Move to 2048-bit RSA

Publish a new selector, test signatures, and keep the previous public key available during the transition.

D
DNSChecker
Site publisher
Published: November 2026
Companion Diagnostic Tool

Verify DKIM Records & Selectors

Test your domain or IP address in real time with our free online network scanner.

Launch Tool

To rotate DKIM keys without interrupting delivery, publish the new public key under a new selector first. Switch your mail service to the new selector only after DNS resolves it. Keep the old record available while messages signed with the old key are still in transit.

RSA key sizes and selectors

RFC 8301, section 3.2 sets the minimum RSA signing key size at 1024 bits and recommends at least 2048 bits. Confirm your mail provider supports 2048-bit keys before migrating.

The DKIM signature header identifies the signing domain with d= and the key selector with s=. A public TXT query for 20230601._domainkey.gmail.com against Google Public DNS on December 3, 2026 returned v=DKIM1; k=rsa; p=… with a 3,600-second TTL. The public key is abbreviated here.

Rotate a selector without interrupting delivery

  1. Generate the new key with your mail provider and add its TXT or CNAME record at the selector name the provider gives you. Keep the private key with the signing service.
  2. Use the Email Authentication Checker to confirm the new selector resolves. For a provider-managed CNAME, follow it to the public key.
  3. Switch the signer, send a test message, and read the recipient’s authentication results. Confirm dkim=pass, the new selector in the signature, and alignment with the From domain if you rely on DKIM for DMARC.
  4. Keep the previous public key through your provider’s recommended overlap and your mail queue retry window. Remove it after confirming that production mail no longer uses it.

Diagnose a failed verification

If the lookup returns no key, compare the exact selector and signing domain in the message header with the DNS record. If the record exists and validation fails, check for truncated TXT data, a mismatch between public and private keys, or mail processing that modified signed headers or body content. Use the DMARC policy guide to investigate alignment separately.

Frequently Asked Questions

Does RFC 8301 prohibit 1024-bit RSA keys?

No. It sets 1024 bits as the minimum and recommends at least 2048 bits. Mail providers can impose stricter requirements.

How do I choose which selector to query?

Read s= and d= from a DKIM-Signature header. Query TXT at s._domainkey.d, substituting the observed values.

Share this technical guide: