Skip to content
  • There are no suggestions because the search field is empty.

How to add a third-party sender without breaking DMARC

To add a third-party sender without breaking DMARC, get the vendor to DKIM-sign your mail with your own domain, and, if it offers a custom Return-Path, point that at a domain you control and authorize the vendor in that domain's SPF record. Then send a test, read the headers, and watch your aggregate reports before you rely on the new source under enforcement. Adding the vendor's include: to your main SPF record is often what the vendor asks for first, but on its own it frequently does nothing for DMARC.

DMARC doesn't care that a vendor is legitimate. It asks one question: did this message carry an SPF or DKIM pass for a domain that aligns with the visible From domain? A vendor that bounces mail through its own domain and signs with its own DKIM d= can pass SPF and DKIM and still fail DMARC for you. At p=none that failure only shows up in reports. At quarantine or reject, receivers are asked to act on it. For legitimate unaligned streams, those shortcomings must be addressed before any attempt to move to enforcement.

What "aligned" means for a vendor

There are two ways a vendor's mail can count for your domain. If the difference between the envelope sender and the From address is new to you, start with Envelope From vs Header From.

  • DKIM route. The vendor signs with d= set to your domain or a subdomain of it, such as d=mail.example.com for mail from news@example.com. You publish the public key, either as a TXT record or as a CNAME pointing to a key the vendor hosts (DKIM selectors and DNS records).
  • SPF route. The vendor sends with a MAIL FROM (Return-Path) domain that's yours, often a subdomain like bounce.example.com, and that domain's SPF record authorizes the vendor. DMARC "relies solely on SPF validation of the MAIL FROM identity," so this is the only SPF result that counts.

Either one is enough for DMARC to pass. You need at least one aligned identifier, and preferably two. Under the default relaxed alignment, a subdomain such as bounce.example.com aligns with example.com (Identifier alignment for SPF and DKIM).

The trap is the apex include:. If the vendor's Return-Path is bounces.vendor.example, SPF is checked for the vendor's domain, passes there, and isn't aligned with example.com. Your include was never consulted. Google's instruction for third-party senders covers this: "Make sure the provider's envelope sender domain matches your domain".

At p=reject, DKIM isn't optional

Domains that publish p=reject must not rely solely on SPF to secure a DMARC pass and must apply valid DKIM signatures to their messages. The reason is forwarding: forwarded mail will most likely fail SPF checks, while DKIM signatures will generally remain valid in these relay situations. So treat aligned DKIM as the main route for every vendor, and SPF as the second one. The trade-offs are in SPF include vs DKIM from the vendor.

A safe onboarding checklist

This is our working method, built from the rules above.

  1. Record the request. Write down the vendor, the business owner, the From address and domain it will use, the message type (marketing, transactional, invoices), and the expected volume. Reports can show that a source exists, but not why. A change process can. Who usually owns SPF, DKIM, and DMARC helps decide who signs off.
  2. Choose the From domain on purpose. Apex or a dedicated subdomain? Microsoft recommends a subdomain for "email services that aren't under your direct control (for example, bulk email services)," so their problems don't affect the reputation of your main domain. The trade-offs are in Shared domains and multi-service setups.
  3. Set up aligned DKIM in the vendor first. Vendors call it different things, such as domain authentication or custom DKIM. Publish exactly the records the vendor gives you, at the host names it gives you. Then confirm in the vendor's console that signing with your domain is switched on. Publishing the record doesn't make the vendor sign.
  4. Make SPF align if the vendor supports it. Use the vendor's custom Return-Path or MAIL FROM feature. That's usually a subdomain with its own SPF record, and sometimes an MX or CNAME as well. Add the vendor to the SPF record of the domain that actually appears in MAIL FROM, which may be that subdomain rather than your apex.
  5. Keep SPF valid. - One v=spf1 record per name. A second record for the new vendor makes SPF return permerror (Multiple SPF records (why that is invalid)). - Count lookups. include, a, mx, ptr, exists, and redirect count toward the limit of 10, and nested includes count too (The 10-lookup limit and SPF permerror). Microsoft puts it plainly: "having fewer than 10 include: statements doesn't guarantee fewer than 10 DNS lookups." - Our stance for sending domains is ~all. An SPF hard fail can get a message rejected before DMARC is evaluated, even when aligned DKIM would have passed. Microsoft 365's own examples end in -all. The trade-off is in Softfail vs fail (~all vs -all).
  6. Test before you trust it. Send a real message from the vendor to a mailbox you control and read the Authentication-Results header. You want dkim=pass with header.d= in your domain, or spf=pass with smtp.mailfrom in your domain, and dmarc=pass. For example:

Authentication-Results: mx.example.net; dkim=pass header.d=example.com header.s=vendor1; spf=pass smtp.mailfrom=bounce.example.com; dmarc=pass header.from=example.com

A "domain verified" badge in the vendor's console isn't the same thing. Check the headers. 7. Confirm in aggregate reports. Over the following days, the new source should show aligned passes at several receivers. The fields to look at are explained in A field-by-field walk-through of a DMARC aggregate report, and how to fold the source into your inventory is in How to inventory sending sources. 8. Only then rely on it under enforcement. If you're already at quarantine or reject, finish steps 3 to 7 before the vendor sends live mail, or start the vendor on a new subdomain that has its own p=none record while you test. 9. Offboard cleanly. When you retire a vendor, wait until its mail has stopped appearing in reports, then remove its include and DKIM records. Review the SPF record periodically and remove senders you no longer use. Stale includes use up lookups and authorize servers you no longer need.

When the vendor can't align

Some tools can't sign with your domain and can't use a custom Return-Path. You can't fix that in your DMARC record: there's no generally accepted mechanism for a domain owner to list third-party DKIM or MAIL FROM domains as authorized. Alignment is the only way in.

Your options, roughly in order of preference:

  • Ask the vendor whether DKIM signing with your domain is available. It's the option that holds up best under enforcement and forwarding.
  • Send that vendor's mail from a subdomain set up only for it, so its failures don't hold back the rest of the domain.
  • Let the vendor send from its own domain, with your address only in Reply-To. Your DMARC policy doesn't apply to mail whose From domain isn't yours.
  • Don't use the tool for mail that has to carry your domain.

What to avoid is keeping the whole domain at p=none for one vendor. The symptom-side version of this problem is in Third-party mail fails alignment.

A note on delegated DKIM

Publishing a vendor's DKIM key lets that vendor sign as your domain. There are two models: you publish a public key the vendor gives you, or you delegate the selector to the vendor, usually with a CNAME, and revoke by removing the delegation. Managing DKIM keys with a third party has security risks that should be carefully managed, and methods involving CNAMEs or subdomains may alleviate some of those risks. Keep a list of which selector belongs to which vendor, so you know what to remove when the contract ends.

Mistakes worth avoiding

  • Adding the include to the apex while the vendor's MAIL FROM is the vendor's own domain. SPF passes for the vendor and isn't aligned.
  • Publishing DKIM records and never switching signing on in the vendor's console.
  • Publishing at the wrong host name. Some DNS hosts append the zone, so selector._domainkey.example.com ends up as selector._domainkey.example.com.example.com.
  • Creating a second SPF record for the new vendor.
  • Blowing the 10-lookup limit with nested vendor includes.
  • Enforcing before the vendor's first scheduled send shows up in reports. A monthly invoice run or a quarterly campaign takes time to appear. It may take many months to be sure all your mail is authenticated.
  • Leaving the vendor in SPF after you stop using it.

For a longer explanation of why SPF and DKIM pass but don't align, see our post on authentication alignment issues. What different kinds of tools need is in Email sending platforms: SPF, DKIM and DMARC setup.

Free DMARC account

Not sure which sender is failing?

Connect your domain's DMARC reports and see every service that sends as your domain, and whether each one passes SPF, DKIM and DMARC.

  • Every sending source in one dashboard
  • SPF, DKIM and alignment results per sender
  • No XML files to read

Create a free DMARC accountTalk to an expert

FAQ

Do I need both SPF and DKIM for a vendor?

DMARC needs one aligned pass, and two is better. If you publish p=reject, aligned DKIM is required.

The vendor says my domain is verified, but DMARC still fails. Why?

Usually the vendor is still signing with its own d=, or its MAIL FROM is still its own domain. Check the Authentication-Results header of a real message.

Where do I add the include if the vendor uses a custom Return-Path?

In the SPF record of the Return-Path domain the vendor uses, which is often a subdomain. Follow the vendor's current instructions for the exact value.

Can I approve a vendor in my DMARC record?

No. DMARC has no list of authorized third parties. The vendor's mail has to align.

How long should I monitor before enforcing?

Long enough to see each sender's full cycle, including monthly and quarterly sends. Unfamiliar sources in reports are covered in Reports show sources we do not recognize, and the rollout itself in A safe rollout: p=none to quarantine to reject and When you are ready for p=reject.