Fix guides › DKIM › Cloudflare › Mailgun
How to set up DKIM on Cloudflare for Mailgun
DKIM signs your email so inboxes know it really came from you. Here is where Mailgun's records come from and where they go at Cloudflare.
Check your Cloudflare DKIM records now
A free check of your domain's live public records. Nothing is changed.- What we found: We read your live DKIM records and tell you whether Mailgun is set up. Free, about 10 seconds.
- Why it matters: It reads your own records, so you see your own problem, not a general one.
- What to do: Type your domain and press Check.
The records Mailgun gives you
DKIM keys are made for your account, so copy them from the service.- What we found: Mailgun gives you one DKIM TXT record made for your domain. It may list more than one key, and not all of them need to be verified.
- Why it matters: DKIM signs each email so inboxes know it really came from you. Without it, DMARC can fail and email lands in spam.
- What to do: Copy the records here: In the Mailgun control panel: open your domain and find the Domain Verification & DNS section. Copy the DKIM TXT record, then click Verify DNS settings once it's in.
Where to add it at Cloudflare
Cloudflare's own steps for adding a TXT record, from its help pages.- What we found: Cloudflare calls the fields Name and Content. For the domain itself, the name is @.
- Why it matters: Add each record Mailgun gives you.
- What to do: Follow Cloudflare's steps:
- Sign in to the Cloudflare dashboard and select your domain.
- Go to the DNS Records page.
- Select Add record and choose TXT as the Type.
- Fill in the fields as shown.
- Select Save.
More guides
Where each fact on this page comes from, and the same guide for other setups.- What we found: Checked against Mailgun docs: domain verification, Cloudflare docs: create DNS records (updated 2026-05-06), Cloudflare docs: zone apex records on 2026-11-15. We check them again every 90 days.
- Why it matters: Screens and values change. Dated sources tell you this page is current.
- What to do: Same guide at: GoDaddy · Namecheap · Wix · Bluehost · Hostinger · Amazon Route 53 · IONOS. Other guides for Mailgun on Cloudflare: SPF · DMARC · Email going to spam. All fix guides.
Company and product names are trademarks of their owners and are used only to describe how to set up your domain with them. DNSFix™ isn't affiliated with or endorsed by them.