Bouncewise

Bouncewise › Guides › Mailgun suppressions: bounces, complaints and unsubscribes

Mailgun guide

Mailgun suppressions: bounces, complaints and unsubscribes

Updated · 2 min read

Short answer

Mailgun keeps three suppression lists for each sending domain: bounces, complaints and unsubscribes. A message to an address on any of them is not attempted; it is logged as a permanent failure such as "Not delivering to previously bounced address". You can remove an address under Send › Sending › Suppressions or with DELETE /v3/{domain}/{bounces|complaints|unsubscribes}/{address}, but only once the cause is fixed, or it will be suppressed again.

The three lists

ListAn address is added whenWhat Mailgun storesAPI
BouncesThe receiving server said the recipient doesn't exist or is invalid (a hard bounce)Address, SMTP code, SMTP error, created_at/v3/{domain}/bounces
ComplaintsThe recipient clicked "report spam" at a mailbox provider that sends feedback-loop reportsAddress and date/v3/{domain}/complaints
UnsubscribesThe recipient clicked a Mailgun unsubscribe link (%unsubscribe_url%, %tag_unsubscribe_url%)Address, date, and * for domain-wide or the tag they left/v3/{domain}/unsubscribes

Not every failure lands on the Bounces list. Temporary failures (a full mailbox, throttling) don't. Nor do permanent failures caused by an ESP blocking you for reputation, or by retries running out: delivery stops, but the address isn't added.

Suppression list for a Mailgun domain, with bounced, complained and unsubscribed addresses and the server's reply for each bounce
Each bounce keeps the SMTP code and error that put it there.

What a suppressed send looks like

Your API call succeeds (Mailgun accepts the message), then the log shows a failed event straight away with no delivery attempt. Mailgun's example of a send to a bounced address:

"event": "failed",
"severity": "permanent",
"reason": "suppress-bounce",
"delivery-status": {
  "code": 605,
  "description": "Not delivering to previously bounced address"
}

Code 605 is Mailgun's own, not an SMTP reply: nothing was sent to the recipient's server. Allowlisting an address can help with an address that keeps bouncing, but Mailgun won't deliver to an address on the Complaints or Unsubscribes list even if it is on the allowlist.

Suppressions are per domain and per region

Lists belong to one sending domain. An address that bounced from mg.example.com is not suppressed for news.example.com, and clearing it on one domain doesn't clear it on the other. Suppressions are also region-bound data, so call the API host of the domain's region: api.mailgun.net for US domains, api.eu.mailgun.net for EU domains (see US vs EU region).

Check and remove an address with the API

# why is [email protected] suppressed?
curl -s --user "api:$MAILGUN_API_KEY" \
  https://api.mailgun.net/v3/mg.example.com/bounces/[email protected]

# remove it from the bounces list
curl -s --user "api:$MAILGUN_API_KEY" -X DELETE \
  https://api.mailgun.net/v3/mg.example.com/bounces/[email protected]

The lookup returns address, code, error and created_at, or 404 if the address isn't on that list. Use /complaints/ or /unsubscribes/ for the other lists. Listing takes limit (default 100, max 1000) and returns paging.next URLs to follow.

Mailgun's wording on each delete is exact about what happens next: delivery resumes "until it bounces again", "until there is another complaint", or "until it unsubscribes again". DELETE /v3/{domain}/bounces without an address clears the whole list, as does Remove all in the control panel.

Before you remove anything

  • Bounces: read the stored error. If it says the mailbox doesn't exist, removing it only earns another hard bounce. Remove it only when the recipient confirms the address now works (a typo fixed, a mailbox recreated).
  • Complaints: removing an address resumes mail to someone who reported you as spam. Do it only when they ask for mail again, ideally in writing.
  • Unsubscribes: remove only on an explicit re-subscribe.

Mailgun's advice is to remove suppressed addresses from your own contact lists (CRM, database), not from the suppression list. Otherwise the cycle starts again and your bounce and complaint rates climb.

Questions

Does a soft bounce add an address to Mailgun's suppression list?

No. Temporary failures such as a full mailbox are retried and don't add the address to the Bounces list.

Why was my email not sent with "Not delivering to previously bounced address"?

The address is on that domain's Bounces list from an earlier hard bounce. Check the stored error, and remove the address only if the mailbox now exists.

Can I import suppressions from another provider?

Yes. Each list has an import endpoint that takes a CSV file of up to 25 MB, and you can POST up to 1000 records as JSON.

Does the allowlist override suppressions?

Not for complaints or unsubscribes: Mailgun won't deliver to an address on those lists even if it is allowlisted.

Sources