To avoid email spoofing, Salesforce encourages customers to include the Salesforce Sender Policy Framework (SPF) record in their domain's SPF record and to implement DomainKeys Identified Mail (DKIM) so that Salesforce signs outbound emails sent on the company's behalf.
If the email domain has a Domain-based Message Authentication, Reporting & Conformance (DMARC) policy, either SPF or DKIM must pass and be in alignment, as defined by DMARC. This article explains the root causes of SPF and DKIM alignment failures in Salesforce email delivery.
To confirm whether an alignment issue exists, use a web-based header analyzer such as the Message Header Analyzer tool.
SPF and DKIM alignment failures in Salesforce email delivery are resolved by setting up a DKIM key, or, if that is not possible, by setting up SPF and disabling Bounce Management and Email Security Compliance. The sections below explain the causes and the steps.
SPF alignment fails when Bounce Management, Email Security Compliance, or both settings are enabled. If either setting is enabled in your organization, the envelope sender address changes to a Variable Envelope Return Path (VERP) address such as "sampleemail=salesforce.com__abc123@abc123.bnc.salesforce.com". This does not meet the DMARC alignment requirement because the Envelope Sender does not match the domain in the From header.
As long as DKIM signing passes in alignment, DMARC does not require SPF to also be aligned. For customers who want to continue using Bounce Processing, Salesforce recommends setting up DKIM.
Note: Leaving Bounce Management active in Salesforce does not ensure successful email delivery because of the mismatch between the Envelope Sender and the From header. Emails can be rejected or sent to spam folders depending on the recipient's email server policies.
DKIM alignment fails when the Domain field in the DKIM key does not match the domain in the From header.
Set up a DKIM key in Salesforce. The contents of the Domain field must match the Domain Match Pattern field.
If you cannot set up a DKIM key, Salesforce recommends the following alternate solution:
Vote and comment on the Idea - We require a way to not have to disable Bounce Management for SPF & DKIM Keys
000381292

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.