550 5.7.30 and 421 4.7.30: DKIM did not pass

Quick fix

Turn on DKIM signing with your own domain in the sending service and publish the key it gives you at selector._domainkey.example.com.

How to fix it

  1. Open a sent message and find the DKIM-Signature header: note the d= domain and the s= selector. No header means the service does not sign.
  2. Turn on DKIM signing with your own domain in the sending service and publish the key it gives you at selector._domainkey.example.com.
  3. Use a key of at least 1024 bits; Google recommends 2048 bits where your DNS host supports it.
  4. If the key is published but DKIM still fails, look for a system that changes the message after signing, such as a footer or a link rewriter.
  5. Send a test to a Gmail address and open Show original: DKIM should show PASS for your domain.

Learn more: DKIM explained: selectors, keys and rotation

How to check

The DKIM check looks up the key for a domain and selector. Take both from the DKIM-Signature header of a sent message: the d= and s= tags. The mail configuration check tries common selectors and shows SPF and DMARC in the same report.

The DKIM record check opens with your domain filled in; it runs when you press Check.

Tools to check it

What the error means

Full error text: 550 5.7.30 This message was blocked because it didn't pass DKIM authentication. Gmail requires bulk email senders to authenticate their email with DKIM.

421 4.7.30 (rate limited) and 550 5.7.30 (blocked) are Gmail's errors for a bulk sender's message that did not pass DKIM. Gmail requires senders of more than 5,000 messages per day to Gmail accounts to set up both SPF and DKIM, so a message that passes SPF can still get this error.

Google's list of Gmail SMTP errors has two texts:

  • 421 4.7.30: "Your email has been rate limited because DKIM authentication didn't pass for this message. Gmail requires all email bulk senders to authenticate their email with DKIM."
  • 550 5.7.30: "This message was blocked because it didn't pass DKIM authentication. Gmail requires bulk email senders to authenticate their email with DKIM."

The 550 text adds "Authentication results: DKIM = did not pass". The usual causes, each with its source:

  • The message is not signed, or signed by the service's domain only. Google's guidelines: "Turn on DKIM for the domain that sends your email."
  • No key at the selector. RFC 6376 section 3.6.2.1: for d=example.com and s=foo.bar "the DNS query will be for "foo.bar._domainkey.example.com"."
  • A revoked key. RFC 6376 section 3.6.1, the p= tag: "An empty value means that this public key has been revoked."
  • A short key. Google: "Sending to personal Gmail accounts requires a DKIM key of 1024 bits or longer."
  • A changed message. RFC 6376 section 3.4: "Some mail systems modify email in transit, potentially invalidating a signature." See DKIM body hash did not verify.

Sources

All findings