This guide walks through setting up an SMTP account with Mailtrap and entering the values into the Application Platform. Mailtrap offers two products: Email Sending for real delivery (which we set up here) and an Email Sandbox for safe testing.
Overview diagram
The delivery path: your application uses the SMTP credential stored on the platform and talks to Mailtrap; Mailtrap delivers the message to the recipient’s domain.
flowchart LR
subgraph platform["Application Platform"]
cred["Organization SMTP credential"]
end
subgraph app["Project backend"]
svc["Outbound mail"]
end
subgraph mailtrap["Mailtrap"]
relay["SMTP relay (Email Sending)"]
end
subgraph dest["Recipient"]
mx["Recipient mail server"]
end
svc -->|"reads config"| cred
svc -->|"TLS, port 587"| relay
relay --> mxSteps in Mailtrap
- Create or open your account at mailtrap.io and sign in.
- Add a sending domain: enter your sender domain under Sending Domains. Mailtrap shows you the DNS records (SPF, DKIM, DMARC) to set at your domain provider – sending is only enabled after verification.
- Get the SMTP credentials: open Integration → SMTP for the verified domain. Mailtrap shows you host, port, username, and the API token used as the password.
- Optional: send a test email to verify the setup.
Entry in the Application Platform
Create a new SMTP credential under Email delivery and enter the values from the Mailtrap integration page:
| Platform field | Value at Mailtrap (Email Sending) |
|---|---|
| SMTP host | live.smtp.mailtrap.io |
| SMTP port | 587 (STARTTLS) |
| SMTP user | api |
| SMTP password | Your Mailtrap API token |
| Sender address | An address of your verified sending domain |
| Sender name | Display name for recipients |
Save – your projects can then use the credential for sending.
sandbox.smtp.mailtrap.io): the sandbox never delivers to real recipients but catches mails in a test inbox. For production sending you need the values from Email Sending.Tip: sandbox for testing
For development and staging you can create a second SMTP credential with the sandbox credentials: all mails then land in the Mailtrap test inbox instead of reaching real recipients – including HTML and spam checks.
Troubleshooting
- Authentication failed: the username must be
api, the password is the API token – check that it was copied completely. - Sending rejected / not delivered: sending domain not verified yet – check the DNS records (SPF/DKIM/DMARC) under Sending Domains.
- Mails end up in the test inbox: you are accidentally using the sandbox credentials instead of Email Sending.