DKIM Verification Error with b= Tag Invalid or Incomplete
Fix DKIM verification errors with b= tag invalid or incomplete. Diagnose and resolve email authentication issues to improve deliverability and inbox.
What causes a DKIM verification error with the b= tag?
You sent a perfectly formatted email, but the recipient’s inbox still flagged it as unverified. Why? A DKIM verification error with the b= tag invalid or incomplete is often the culprit—especially when your email appears to pass all other checks.
The b= tag is the core of a DKIM signature: it’s the cryptographic hash of your message’s body and selected headers. If that hash is missing, malformed, or cut short—due to a tiny change in whitespace or a misconfigured DNS record—the entire signature fails. It’s like a digital fingerprint: one smudge, and the system rejects the match.
Key takeaways
- The b= tag must contain the correct cryptographic hash of exactly the message body and headers as they were signed; any deviation invalidates the signature.
- Even minimal changes—like adding a newline, modifying whitespace, or applying incompatible MIME encoding—can break DKIM validation.
- Proper DNS configuration for DKIM, correct key length, and consistent handling of message content through all transit stages are essential to avoid b= tag errors.
Why does a malformed b= tag break email deliverability?
When the b= tag in a DKIM signature is malformed or incomplete, email receivers can't verify the message's authenticity, even if the DNS record is correct. This failure means the email is rejected by providers like Gmail and Outlook, often landing in spam folders or being blocked entirely. Over time, repeated failures harm your sender reputation and increase the risk of being added to blocklists.
How DKIM verification works in practice
Every email sent with DKIM includes a digital signature with a b= value derived from hashing the message body and selected headers. Recipients retrieve your public key from your domain’s DNS records and use it to recompute the hash. If the result doesn’t match the b= value, the signature is invalid.
According to RFC 6376, the standard governing DKIM, the signature must be correctly formatted and mathematically consistent. Even a single incorrect character — like a missing padding or an encoded value that fails decoding — breaks the chain. This isn’t just a technical formality; it’s a core part of email security.
What happens when DKIM fails
Providers use DKIM validation as a signal to assess legitimacy. A failed DKIM check doesn't guarantee spam, but it lowers trust. Gmail, for example, has been known to treat consistent DKIM failures as a red flag, especially when combined with other poor signals like low engagement or high bounce rates.
When DKIM fails repeatedly across your sending volume, your overall sender reputation degrades. Email services track this behavior over time, and persistent issues can lead to throttling or blacklisting—especially if the same domain shows signs of spoofing or inconsistent authentication.
Let’s be clear: a malformed b= tag is a technical error, not a policy violation. But it's one that email receivers treat as serious. Fixing it isn't optional—it’s foundational.
You can test whether your DKIM setup is working correctly before sending. Use MailTester’s inbox placement tester to simulate real-world delivery and catch issues like this in advance. It checks not just DKIM, but also SPF, DMARC, and spam score in context.
How DKIM signatures actually work (the plain-English breakdown)
When an email is sent, the server creates a unique digital fingerprint of the message using a secret private key. This fingerprint—called a DKIM signature—is stored in the email header as a hash under the b= tag. The receiving server checks this by fetching the matching public key from DNS, re-creating the hash with the same rules, and comparing it to the b= value. If they don’t match, you get a "b= tag invalid or incomplete" error, meaning something went wrong in the signing or verification process.
Step-by-step: The DKIM verification journey
- Message normalization — The sending server takes the email and applies a strict set of rules to clean up variations in formatting, like line breaks or extra whitespace. This is called canonicalization. It ensures that two identical messages always produce the same hash, regardless of how they’re written.
- Hash generation — Using the canonicalized body and a selected set of headers (like From, Subject, Date), the server computes a cryptographic hash. This is done with a private key specific to the sending domain, creating a unique code that only matches that domain’s key pair.
- Embedding the signature — The resulting hash is encoded in base64 and inserted into the DKIM-Signature header, under the
b=tag. This is the actual fingerprint of the message, tied directly to the sending domain’s private key. - DNS lookup — The receiving server looks up the public key from the sending domain’s DNS records, using the selector in the DKIM-Signature header. This key is used to verify the signature.
- Re-calculation and comparison — The receiver applies the same canonicalization rules to the message, computes a fresh hash using the public key, and checks if it matches the
b=value. If it doesn’t, the signature fails—possibly due to incorrect header selection, encoding errors, or a malformed public key.
What breaks the b= tag during verification?
Common issues include misconfigured DNS records, using a domain that doesn’t support DKIM, or a typo in the selector. Sometimes the signature gets stripped by intermediaries like mailing list servers or content filters. Tools like MailTester’s email checker can help spot these issues before sending by validating alignment and signature format.
According to the DKIM specification (RFC 6376), the entire process relies on consistent canonicalization and proper key management. Even small deviations—like an extra space in a header or a missing DNS record—cause validation to fail.
If you’re seeing “b= tag invalid or incomplete,” double-check the DNS record is published correctly and that your email service is applying canonicalization properly. Many SMTP relays and email platforms handle this automatically, but misconfigurations happen—especially with custom domains or bulk senders.
How to diagnose a b= tag error in real time
You can diagnose a DKIM verification error with a missing or incomplete b= tag by testing your message through a real delivery simulation tool like MailTester’s inbox-placement tester. This gives you a full header analysis across major email providers, revealing whether the b= tag exists, is correctly encoded, and matches the expected length (usually 256+ characters). Compare it to a known-good header to spot subtle issues in whitespace, encoding, or header order that break DKIM validation.
Use real-world delivery testing to catch b= tag errors early
- Run your message through MailTester’s inbox-placement tester to simulate delivery to Gmail, Outlook, Apple Mail, and others. This reveals header-level errors you’d miss with simple syntax checks.
- Check the raw message headers for the
DKIM-Signaturefield. Theb=tag must be present and typically 256 to 336 characters long. A shorter value usually indicates a truncation or signing failure. - Look for anomalies: inconsistent line breaks, embedded spaces where none should be, or a
b=tag that starts or ends abruptly. Such deviations often stem from incorrect signing or misconfigured tools.
Compare with a known-good header to spot subtle issues
- Fetch a header from a message that successfully passes DKIM checks on the same domain (e.g., from a past email that landed in an inbox). Use this as a baseline.
- Compare the
DKIM-Signaturefield side-by-side. Differences in field order, whitespace, or encoding (like URL-encoding vs. plain base64) may be causing theb=tag to be rejected. - Use RFC 6376 as a reference for proper DKIM signature format. The
b=tag must be base64-encoded and include the full signature data without truncation or encoding artifacts. - If your signing tool or library adds extra line breaks or alters header ordering, adjust it. DKIM is strict on exact header representation—the signature fails if even one space differs.
Even a single misplaced space in a DKIM-Signature header can invalidate the entire signature. Consistency in formatting, order, and encoding is non-negotiable.
A closer look: how message body changes break DKIM
Even a single change to the message body—like inserting a tracking pixel, altering line breaks, or converting HTML to plain text—alters the canonicalized version used in DKIM signing. This invalidates the original b= value unless the message is re-signed. Many email service providers and forwarders modify content during transit, which often breaks DKIM unless the new content is re-signed.
What triggers DKIM body changes
DKIM relies on a specific canonicalization of the message body. Any change, no matter how small, breaks that consistency. For example, adding an image pixel for tracking, embedding a URL, or even changing whitespace or line endings changes the body’s digest. These edits mean the b= value no longer matches, causing verification failure.
Let’s say your marketing team auto-injects a tracking image into outbound emails. That pixel gets added at the ESP level, altering the body content even if you didn’t touch the template. The DKIM signature from the original sender now fails, even if the email is fully legitimate.
How ESPs and forwarders interfere
Some email service providers or mailing list forwarders add headers, footers, or rewrite content—like converting HTML to text—during transit. These are common behaviors, especially with newsletters or automated campaigns. But if that processing occurs after the DKIM signature is generated, it nullifies the validation.
According to RFC 6376 (the foundational DKIM specification), the signature must be computed over the canonicalized message body. When the body is altered without re-signing, the b= value is automatically considered invalid. This is why a single pixel can break your email’s trust score even if all other settings are correct.
For instance, if you use a third-party ESP that injects a subscription footer during delivery, and your original DKIM signature wasn’t generated after that change, the validation will consistently fail. This isn’t a flaw in the sender’s code—it’s a consequence of how signed content must remain unchanged from signature to final delivery.
Using a verification tool like MailTester’s email checker helps detect issues like this before you send. It flags problems with DKIM, deliverability risk, and formatting inconsistencies—so you catch potential signature failures before they break in the wild.
DKIM vs SPF vs DMARC: what each role actually does
SPF checks if the sending IP is authorized for the domain. DKIM confirms the email content hasn't been altered since signing. DMARC enforces policies based on SPF and DKIM results and collects reports. Together, they form a layered defense against spoofing and help improve inbox placement. You’re not just sending emails—you’re proving they’re legitimate, not forged.
How each protocol works in practice
Let’s break down what each protocol actually does, step by step, so you’re not just guessing during verification errors.
| Protocol | What it verifies | How it works | Typical issue if broken | Impact on deliverability |
|---|---|---|---|---|
| SPF | Whether the sending IP is authorized to send emails for the domain. | Checks the domain’s TXT record for a list of permitted IPs or mail servers. | IP not listed in SPF record; too many include statements (exceeding 10). | High chance of being flagged as spam or rejected entirely by receivers. |
| DKIM | Whether the email content has been tampered with since signing. | Uses a cryptographic signature in the email header (b= tag) and verifies it via a public key published in DNS. | Invalid or incomplete b= tag; mismatched hash; expired or missing DKIM key. |
Common cause of spam filter rejection, especially when combined with failed SPF. |
| DMARC | Enforces policies based on SPF and DKIM results and collects feedback. | Uses a DNS record to tell receivers what to do if SPF or DKIM fails (e.g., quarantine or reject). Sends reports of failures. | Policy not set; overly strict policy with no monitoring; no reporting setup. | Without DMARC, you’re blind to spoofing. With DMARC, you gain visibility and control. |
DKIM errors with b= tag invalid or incomplete mean the signature didn't validate—either because of a malformed signature, incorrect key, or email content modification during transit. This is common with third-party email service providers that alter headers. According to RFC 6376 (the technical standard), the b= tag must contain a base64-encoded signature that matches the signed content.
Think of it like this: SPF is the guest list. DKIM is the fingerprint on the document. DMARC is the bouncer who checks both and decides what to do if either fails. All three work best together. If one fails, deliverability drops—sometimes dramatically.
Use MailTester’s email checker to verify individual addresses and see if issues like DKIM errors are present before sending. If you're validating bulk lists, our bulk verification tool can surface failed DKIM, SPF, or DMARC results across your entire list—helping you cut down on hard bounces and improve sender reputation.
How MailTester helps you resolve b= tag failures
When your emails show a DKIM verification error with a missing or invalid b= tag, it means the signature’s digital hash doesn’t match the message body. MailTester’s real-time API checks headers and DNS records—including DKIM, SPF, and DMARC—in real time to detect misconfigurations before they trigger bounces or spam filters. Fixing these issues early prevents deliverability drops and sender reputation damage.
Real-time checks catch broken DKIM in headers
Let’s say you’re sending a campaign and get a bounce with a DKIM error. The issue might not be with the email itself, but with a malformed or truncated b= tag in the DKIM signature. MailTester’s API analyzes every incoming or outgoing email’s full header and DNS records—including signature alignment and key validity. Unlike tools that only validate domains, it examines the actual cryptographic digest used in the b= field to confirm it matches the signed content. This deep inspection catches common failures like truncated hashes, incorrect base64 encoding, or key mismatches.
If you’re using services like SendGrid or Mailchimp, integration with MailTester’s API lets you verify every address before sending. The system flags emails with missing, expired, or invalid DKIM records, helping you clean your list in advance. You’re not reacting to bounces—you’re preventing them.
AI-powered insights for error interpretation and fixes
Raw DKIM errors don’t always tell you what’s wrong. A b= tag failure could mean a misaligned selector, an invalid public key, or even a header modification post-signature. That’s where the in-app AI assistant comes in. It reads the full error context—header structure, DNS record status, and signature alignment—and interprets it using known patterns from industry-standard practices.
For example, if the b= value is malformed, the AI may suggest checking your signing library or SMTP relay’s handling of whitespace and line breaks. If the selector doesn’t resolve, it highlights the need to verify the TXT record for the correct DKIM record. This isn’t just a guess—it’s a recommendation based on real-world configurations and common pitfalls documented by RFC 6376 and used by major ESPs. The AI even suggests whether the key should be reissued or if the signing domain is misconfigured.
For teams running regular bulk sends, MailTester’s bulk list verification checks thousands of addresses at once, surfacing every instance of broken DKIM, catch-all responses, or disposable domains. You get a cleaned list before you hit send. Use the real-time API to embed verification into your app or pipeline. Or test an email’s final inbox placement with inbox placement testing to see how your DKIM signature performs in Gmail, Outlook, and other providers. Real, actionable data—no guesswork.
Preventing future DKIM signature errors
DKIM signature errors with a malformed or missing b= tag usually stem from improper message signing after content changes. To prevent this, ensure every modification—like tracking links or auto-signatures—forces a new DKIM signature. Use consistent templates, verify DNS entries regularly, and automate checks on deliverability health to catch issues before they impact your inbox placement.
Keep message templates predictable
- Stick to a single template across campaigns to reduce accidental body changes that break DKIM signatures.
- Use versioned templates and approval workflows to avoid last-minute edits that bypass signing.
- Train teams to treat email content as immutable once signed—changes after signing invalidate the signature.
Ensure re-signing after modifications
- Verify your ESP or email platform re-signs messages after inserting tracking pixels, UTM tags, or auto-signatures.
- Check your email delivery logs to confirm a new
b=value appears after outbound delivery. - Test with tools like MxToolbox or MailTester’s inbox placement tester to validate DKIM integrity in real-world inboxes.
- Use MailTester’s real-time verification API to validate domains and detect misconfigured DKIM records during list hygiene.
Monitor DNS records proactively
- Run quarterly DNS audits of your SPF, DKIM, and DMARC records using RFC 6376 as reference for correct syntax.
- Audit only the published DNS records, not just the ones you think are active—spelling errors or missing subdomains are common culprits.
- Use MailTester’s bulk list verification to identify invalid or malformed addresses before sending.
What to do after fixing a b= tag error
Once you’ve corrected the b= tag issue in your DKIM signature, test the fix immediately with inbox-placement testing. Use MailTester’s inbox-placement feature to send a real message through your configured setup and verify that it passes authentication and lands in the inbox—no more guesswork. Then, monitor sender reputation and review DMARC reports to catch any lingering misalignments.
Step-by-step validation and monitoring
- Run an inbox-placement test using MailTester’s inbox-placement tool. This sends a test message through your actual mail flow and checks for pass/fail signals in DKIM, SPF, and DMARC. It confirms whether the corrected b= tag now passes, and whether the message reaches the inbox instead of spam. This is the only way to validate real-world deliverability, not just technical correctness.
- Monitor sender reputation using tools like SenderScore or Return Path (now part of Cisco Umbrella). These services track your sending behavior, blocklist presence, and historical abuse patterns. A sudden drop in reputation after a DKIM fix may point to other issues—like inconsistent sending volume or poor recipient engagement—so ongoing vigilance matters.
- Check your DMARC reports from your email provider or aggregator (such as Agari, Valimail, or Postmark). These reports show exactly which messages are passing or failing SPF/DKIM alignment and which domains or IPs are sending on your behalf. Look for any remaining failures linked to mismatched identifiers or unauthorized senders, and update your policy if needed.
- Verify your domain’s alignment by ensuring the d= domain in the DKIM signature matches the From: domain in the message. Misalignment can cause rejection even if the b= tag is technically valid. Use RFC 6376 as a reference for correct DKIM implementation.
- Automate future checks by integrating MailTester’s API into your send workflow. This lets you validate each address before sending, catching issues like malformed DKIM signatures early. You can find the API at MailTester’s verification API.
Why this step matters
Fixing the b= tag fixes one piece of authentication—but deliverability depends on the full chain. A single misaligned or malformed signature won’t always block a message, but it weakens your sender reputation over time. Real inbox placement testing shows what actually happens across major providers. Use MailTester’s inbox placement tester to simulate your send environment without sending to real users.
Why DKIM errors don’t always mean your domain is compromised
Seeing a DKIM verification error with an invalid or incomplete b= tag doesn’t mean your domain is hacked or your emails are being spoofed. In most cases, it’s a technical mismatch—often caused by misconfigured DNS, a forwarding service modifying headers, or a third-party email provider rewriting content. These issues can break DKIM signatures without any malicious intent.
Common causes of b= tag failures
Let’s be clear: a failed b= tag doesn’t signal a security breach. The most frequent culprits are misaligned DKIM configurations—like using the wrong selector, incorrect key placement in DNS, or a signature that was generated but never published. Even minor syntax errors in the DKIM record, such as extra spaces or missing line breaks, can cause verification to fail.
More surprisingly, even properly signed emails can fail when they pass through services that rewrite headers—common with email forwarding or bulk mailing platforms. Forwarders sometimes strip or modify DKIM signatures during transit, invalidating the b= tag without harm to the sender. Similarly, ESPs like SendGrid or Mailchimp may automatically sign outbound mail with their own keys, which overrides your domain’s signature.
Don’t panic—focus on consistency
Instead of reacting to every DKIM error, focus on verifying your setup across different environments. Use tools designed to test DKIM records with real-world email flows. MailTester’s inbox placement testing helps you see how your emails appear in real mailboxes, including whether DKIM passes at the receiving end. This gives a far clearer picture than parsing error logs alone.
According to RFC 6376, the DKIM specification intentionally allows for flexibility in signature handling. That means some recipients may reject a valid signature due to strict policies—especially if you’re sending to corporate or government inboxes. This doesn’t make you a threat. It just reflects how different systems interpret the same standard.
Ultimately, persistence is key. A single DKIM failure is expected. But repeated failures across multiple domains or consistent delivery problems should prompt a deeper check. Use a reliable verification tool to audit your list and confirm that your domain’s signing setup is stable. Consistent implementation, backed by real testing, is the true defense—not alarm.
Final take: DKIM isn’t optional—it’s a deliverability baseline
Every major email provider—Gmail, Yahoo, Outlook—validates DKIM signatures. A failed signature, especially one with an invalid or incomplete b= tag, signals to their systems that the message may not be trustworthy.
Fixing b= tag errors isn’t a feature toggle or a branding exercise. It’s a technical necessity. Without a valid DKIM signature, your emails will fail authentication checks and land in spam or get rejected entirely.
Use a tool designed for accuracy and depth. MailTester verifies 98.9% of email addresses correctly—ensuring inbox placement and authentication health are both checked at scale.
Sources
- Since May 5, 2025, Microsoft Outlook requires SPF, DKIM, and DMARC from domains sending 5,000+ emails per day, rejecting non-compliant mail outright at the SMTP level with error 550 5.7.515. — Microsoft Outlook requirements (via MailOver bulk-sender requirements guide) (2025)
- DMARC adoption among top domains surged 75% between 2023 and 2025 — from 27.2% to 47.7% — in the wake of Google and Yahoo's bulk-sender authentication requirements. — EasyDMARC 2025 DMARC Adoption Report (2025)
Keep reading
- Email authentication: SPF, DKIM, DMARC, BIMI and MTA-STS (complete guide)
- Dynamic IP Sending Fails SPF Due to IP4 CIDR Mismatch
- How to Fix SPF Tag Inconsistency on Subdomain Only in Email Authentication
- How to Correct SPF IP4 CIDR Outside Valid Range in 2026
- Email Verification Service Returns 450 Error: What It Means
Ready to put this into practice? MailTester verifies emails with 98.9% accuracy — start with 100 free verifications.
Frequently asked questions
What does a DKIM b= tag error mean?
It means the cryptographic signature in the DKIM-Signature header is malformed, missing, or doesn’t match the message content, causing authentication to fail.
Can a missing b= tag be fixed by re-sending the email?
Only if the sender regenerates the DKIM signature during transmission. Re-sending without re-signing won’t help.
Why does the b= tag sometimes appear blank?
It may be omitted during misconfiguration, or the signing process failed due to invalid key, incorrect canonicalization, or a truncated DNS record.
Does DKIM only matter for bulk emails?
No. Even small batches or personalized emails rely on DKIM to maintain sender trust with inbox providers.
Can a forwarder break DKIM?
Yes. Forwarding tools that alter the message body or headers without re-signing it invalidate the original DKIM signature.
How often should I audit my DKIM setup?
At least monthly, especially after changes to email templates, ESPs, or DNS records. Use automated tools to catch issues early.
What happens if only SPF passes and DKIM fails?
The message may still pass if DMARC policy allows it, but it will be treated with caution. Persistent DKIM failures hurt reputation over time.
Is there a way to test DKIM without sending an email?
Yes. MailTester’s inbox-placement testing and API let you simulate delivery and analyze DKIM headers without sending live traffic.
How does MailTester check for DKIM validity?
It parses the DKIM-Signature header, validates the b= tag format, checks the DNS public key, and confirms the calculated hash matches.
Can MailTester fix DKIM errors for me?
No. It identifies and reports configuration issues. You must fix them in your email system or DNS settings.
Are disposable domains ever trusted with DKIM?
No. Even if a disposable domain has valid DKIM, providers still block such messages due to their transient nature and high spam association.
What’s the minimum length of a valid b= tag?
The b= value is typically 256 characters or longer. Shorter values generally indicate omission or truncation.