Appearance
Mailgun
Mailgun
Sinch's email API with detailed analytics, webhooks, and a generous free trial. Region-aware (US or EU).
Prerequisites
- A Mailgun account. New accounts get 5,000 free emails for 30 days.
- A domain you can edit DNS records for (Mailgun's free sandbox domain only sends to verified addresses).
Step-by-step
Add and verify your domain
Mailgun dashboard → Sending → Domains → Add New Domain.
Pick a region (US or EU — they're separate, fully isolated infrastructures) and enter your domain.
Mailgun gives you a list of DNS records to add: TXT (SPF), TXT (DKIM), optionally CNAME (tracking) and MX records.
Add them at your DNS provider (Cloudflare / Route 53 / GoDaddy / etc) and click Verify DNS Settings in Mailgun. Wait 5-30 min for propagation.
Get your API key
Mailgun → Send → Sending → Domain settings → API security.
Copy your Private API Key. It's also at Settings → API Keys in the top-right user menu.
Add the connection in SendGrail
WordPress admin → SendGrail → Connections → Add Connection → pick Mailgun.
Fill in:
- Connection Name: Mailgun
- Domain: your verified domain (e.g.
mg.yoursite.com) - Region: US or EU — must match where you registered the domain
- From Email: an address on the verified domain
- From Name: display name
- API Key: paste the private API key
Click Save.
Test
SendGrail → Test Email → pick the Mailgun connection → send.
Troubleshooting
Domain not found: yourdomain.com
The domain isn't verified in the region you selected. Double-check the region (US vs EU) — they share the same dashboard but are separate APIs. A domain verified in EU won't work via the US endpoint.
Forbidden
API key is wrong or your account is suspended. Regenerate the key in Mailgun → API Keys.
Emails hit the sandbox limit
Mailgun sandbox domains (the default sandbox*.mailgun.org) only send to verified recipient addresses. Add a real domain in step 1 to send to anyone.
Free trial expired
After 30 days, the free trial ends and unsigned accounts are limited to verified recipients. Add a payment method to keep sending freely.
What's next
- Email Routing — route different email types through Mailgun's analytics-rich pipeline.
- Open / Click Tracking — Mailgun has its own tracking; SendGrail's tracking is independent and works on top.