Auth0 failing to send emails via Mailgun API and SMTP: “Mailgun Request Failed”

Hi Community,

We are debugging an issue where Auth0 is no longer able to send emails through Mailgun.

This setup was working previously, but it suddenly stopped working. We tested both Mailgun API key configuration and SMTP configuration in Auth0, and both fail.

We have already checked the obvious items:

  • Mailgun domain is verified
  • API key is valid
  • New API keys were generated and tested
  • SMTP credentials were tested
  • Sender/domain configuration looks correct
  • IP/access restrictions were checked
  • Mailgun side appears to be working

Auth0 only returns the generic error below:

{
  "date": "2026-06-19T10:37:26.716Z",
  "type": "fn",
  "description": "To: h*****@v*.ae",
  "connection_id": "",
  "ip": "94.206.33.30",
  "details": {
    "email_type": "try_provider_configuration_email",
    "notification_type": "try_provider_configuration_email",
    "to": "h*****@v*.ae",
    "error": "Error sending email: Mailgun Request Failed"
  },
  "user_id": "",
  "user_name": "h*****@v*.ae",
  "environment_name": "prod-us-4",
  "log_id": "90020260619103726808989000000000000001223372116011128380",
  "tenant_name": "virtuzone-referral",
  "_id": "90020260619103726808989000000000000001223372116011128380",
  "isMobile": false,
  "user_agent": "Other 0.0.0 / Other 0.0.0",
  "location_info": {},
  "id": "90020260619103726808989000000000000001223372116011128380"
}

The problem is that the Auth0 log does not expose the actual Mailgun response, so it is difficult to know whether this is a Mailgun rejection, Auth0 provider issue, region/domain mismatch, sender validation issue, or tenant-level problem.

Has anyone seen this before?

Specifically looking for guidance on:

  1. Possible causes when both Mailgun API and SMTP fail from Auth0
  2. How to get the underlying Mailgun error from Auth0
  3. Whether Auth0 has any known issues or restrictions with Mailgun provider configuration
  4. What else should be checked when Mailgun works externally but Auth0 returns only “Mailgun Request Failed”

Any direction would be appreciated.

Hi @hassan.ali

Welcome to the Auth0 Community!

To answer your questions:

  1. When both API and SMTP fail simultaneously despite working externally, the culprit is almost always a Region Mismatch (US vs. EU endpoints), a strict From Address mismatch, or a silent account restriction on the Mailgun side (e.g., billing limits or sandbox domain expiry).

  2. Auth0’s dashboard logs intentionally swallow the verbose HTTP response body from third-party email providers for security and abstraction reasons. You generally cannot extract the exact Mailgun JSON error directly from Auth0’s UI. I would highly recommend checking the logs from their end as they might be more explicit regarding the failure.

  3. The most common known issue with the native Auth0 Mailgun provider is misconfiguring the Mailgun Region dropdown, causing Auth0 to route valid credentials to the wrong geographical Mailgun API endpoint.

  4. You must bypass Auth0’s logs and look at Mailgun’s incoming request logs, or use a diagnostic proxy (like Mailtrap) to inspect exactly what Auth0 is attempting to send out.

I would recommend to:

→ Double-check your geographical routing.

  • If using the native Mailgun Provider in Auth0: Ensure the “Region” dropdown exactly matches where your domain is hosted in Mailgun.

  • If using Custom SMTP: Explicitly verify if you should be using smtp.eu.mailgun.org instead of smtp.mailgun.org.

→ Since Auth0 won’t show the error, you must look at the receiver.
Go to your Mailgun Dashboard > Sending > Logs. Do not just look for “Failed” deliveries; look for HTTP API errors. If your request is reaching Mailgun but failing validation (e.g., a From address mismatch), it will appear here. If nothing appears here, it confirms an authentication failure (invalid key/region) where Mailgun drops the request before logging it to your domain.

→ To prove whether the issue is Auth0 failing to assemble the email or Mailgun rejecting it, temporarily switch your Auth0 Email Provider to Custom SMTP and use credentials from a service like Mailtrap.io.

  • If the test email successfully arrives in your Mailtrap inbox, Auth0 is working perfectly, and the issue is 100% strictly a Mailgun policy, region, or credential rejection.

  • If the test email fails to reach Mailtrap, there may be a deeper issue with your tenant’s email configuration (such as a malformed template) that is causing the internal Auth0 worker to crash before the request even leaves the Auth0 network.

Kind Regards,
Nik