Sending

Mailgun sandbox domain: what it allows and how to send for real

Short answer

Every new Mailgun account gets a sandbox domain for testing. It can only send to authorized recipients that you add in the control panel, and the same rule applies to routes and mailing lists on that domain; Mailgun's docs mention a cap of 5 authorized participants. If sandbox emails are not arriving, the recipient is usually not authorized. To send to anyone, add and verify your own domain, which the free plan allows (one domain, 100 emails a day).

Last checked 16 November 2026

Every new Mailgun account comes with a sandbox domain for testing. It works for sending, but only to authorized recipients: addresses you add to an allow list in the control panel. Send to anyone else and the message will not go through. That is the cause of most “Mailgun sandbox not sending email” problems. To send to real users, add and verify your own domain. The details below come from Mailgun’s sandbox domain docs, checked 16 November 2026.

What the sandbox domain allows

Sandbox domain Your own verified domain
Created Automatically, for every new account By you, after DNS verification
Who you can send to Authorized recipients only Anyone
Authorized recipient cap Docs mention 5 authorized participants Not applicable
Routes and mailing lists Limited to authorized recipients Normal
Intended use Testing only Production

Mailgun’s docs state that sandbox domains can only send to authorized recipients, and that the same restriction applies to routes triggered by addresses on the sandbox domain and to mailing lists created under it.

How to add an authorized recipient

  1. Open the Mailgun control panel and select your sandbox domain.
  2. Go to the Setup tab in Domain Settings.
  3. Add the address under authorized recipients.
  4. Follow any confirmation step the control panel shows for that address.

Once the address is on the list, sends from the sandbox domain to that address should go through. Keep the list to your own and your team’s addresses. It is a testing tool, not a way to send to customers.

Why your sandbox emails are not arriving

Work through these in order:

  1. The recipient is not authorized. This is the usual cause. Check the address is on the list exactly, including any plus label.
  2. You are over the free plan’s volume. The free plan allows 100 emails a day according to the figures we recorded from mailgun.com/pricing on 16 November 2026. Our Mailgun sending limits page covers the plan and rate limits.
  3. The email is in spam. A sandbox domain is a shared Mailgun test domain, not your brand, so mailbox providers may treat it with suspicion. Check the spam folder before assuming it failed.
  4. You are using the wrong API host. Accounts in Mailgun’s EU region use a different API host from US accounts. The domain and the host must match.
  5. Check the logs. Mailgun’s logs show whether the message was accepted, delivered or rejected. On the free plan, logs are kept for 1 day, so look soon after sending.

How to send to anyone: use your own domain

There is no “leave sandbox” button. Instead, you add your own domain and send from it:

  1. In the control panel, add a domain. A subdomain such as mg.yourdomain.com or mail.yourdomain.com keeps your app’s sending separate from your staff mailboxes.
  2. Publish the DNS records Mailgun shows: SPF, DKIM, and the MX and tracking records if you use them.
  3. Verify the domain in Mailgun.
  4. Change your code’s from address and the domain in the API path from the sandbox domain to the new one.

The free plan includes one domain and Basic also includes one. Foundation and Scale allow 1,000 (mailgun.com/pricing, checked 16 November 2026). If you need a second domain, that is the point at which the plan changes.

Once you send from your own domain, also add a DMARC record. Gmail and Yahoo require DMARC for bulk senders, as our bulk sender rules guide explains, and it helps every sender.

Testing after you leave the sandbox

You do not need the sandbox to test safely. Common options are a separate verified staging subdomain with sends only to your own addresses, a local SMTP catcher in development, and mocked HTTP calls in unit tests. Keep test traffic away from made-up addresses at real domains, because those produce real bounces that count against your reputation.

Sandbox domain or staging domain?

Once you have a verified domain, a common question is whether to keep using the sandbox for tests. The sandbox is handy for a first try of the API, but a verified staging subdomain, such as staging.mail.yourdomain.com, is usually the better long-term setup. It sends with your own SPF and DKIM, so you test the same authentication your users will see, and it is not limited to a short list of authorized recipients. Keep staging sends to addresses you own, and keep its volume separate from production so your main domain’s reputation is not affected by test traffic. Note that on Mailgun’s free and Basic plans a second domain needs a plan with more domains.

How Mailcandor compares

Mailcandor’s sandbox is per team rather than per domain. A new team can only send to members of the team, and any other recipient is refused with a clear 403 sandbox_recipient error that lists the addresses not allowed, rather than a silent failure. Verifying the first domain moves the whole team out of the sandbox for good. Every plan has unlimited domains, and the free Starter plan allows 100 emails a day and 3,000 a month. See the sandbox explained.

Moving from Mailgun means changing the send call, as there is no Mailgun-compatible endpoint. Our migration guide walks through it. See also the comparison and pricing. Access is currently by request.

Questions

What is the Mailgun sandbox domain?

A domain Mailgun creates automatically for every new account, for testing only. It looks like sandbox followed by a long id at mailgun.org, and it only sends to authorized recipients.

Why is my Mailgun sandbox not sending email?

Most often the recipient is not on the sandbox domain's authorized recipients list. Add the address under the sandbox domain's settings, or send from your own verified domain instead.

How many authorized recipients can a Mailgun sandbox have?

Mailgun's sandbox domain docs mention a cap of 5 authorized participants (checked 16 November 2026).

How do I get out of the Mailgun sandbox?

There is no switch. Add your own domain, publish its DNS records, verify it and send from an address on it. The free plan includes one domain.

Can I use the Mailgun sandbox domain in production?

No. Mailgun says the sandbox domain is for testing purposes only.

Related

Send with someone on your side.

Unlimited domains on every plan, a person before any block, and 3,000 emails a month free. Tell us what you send and we set you up within one business day.