Help
Setting up Mailgun.
Add your domain in Mailgun, paste one API key into Newsletter Sender, and you are ready to send. Setup takes about 10 minutes, most of which is simply waiting for DNS records to propagate.
1Before you start
- A Mailgun account: sign up at mailgun.com if you haven't already.
- Your sender address: check your From address (such as
news@yourdomain.com) in Newsletter Sender under Settings → Your company. Mailgun must be set up for this address's domain.
2Add and verify your domain in Mailgun
- In Mailgun, open Send → Sending → Domains and click Add new domain. Mailgun suggests a subdomain such as
mg.yourdomain.com, which keeps your main domain's reputation separate. Choose EU if your Mailgun account is in Europe. - Mailgun lists the DNS records: TXT records for SPF and DKIM, and MX and CNAME records. Add them where your domain's DNS is (see the tips below).
- Click Verify DNS settings.
- If your DNS is on Cloudflare: go to DNS → Records → Add record. Set any CNAME records to DNS only (grey cloud), not Proxied (orange cloud), or Mailgun can't verify them.
- If your DNS is elsewhere: copy each name and value into your DNS host's dashboard (such as GoDaddy or Namecheap).
DNS records typically take effect within a few minutes, though some hosts take up to a few hours.
3Make an API key
- Open your name at the top right, then API Security (or API keys). Use an account API key, not a domain sending key: a sending key can only send, so we couldn't add the bounce webhooks for you.
- Click Add new key, give it a name such as
Newsletter Senderand copy it. Mailgun only shows it once.
4Connect Mailgun to Newsletter Sender
- In Newsletter Sender, go to Settings → Sending and select Mailgun.
- Paste the key into API key, type your Mailgun sending domain, such as
mg.yourdomain.com, and choose the same Region as your account (US or EU). - (Optional) Sending rate: enter your account's limit under Emails per second. Leave it blank to use the default of 20 a second.
- Click Save.
Newsletter Sender checks the API key with Mailgun and sends a test email to your own address. Once it works, your API key is encrypted inside your own Cloudflare account and hidden from view.

5Automatic bounce and complaint tracking
When you click Save, Newsletter Sender uses your API key to add its webhook for you.
This means every hard bounce and spam complaint comes straight back to Newsletter Sender, and those contacts are never emailed again. Once it's active, Settings → Sending shows a green tick.
If the webhook couldn't be added automatically
The page shows an Add it for me button to try again, alongside the webhook address to add yourself:
- In Mailgun, open Send → Sending → Webhooks and choose your domain.
- Add the address for Permanent failure, Temporary failure and Spam complaints.