Quickstart Guide
To start sending emails with Mailgun, follow these steps:
1. Sign Up
Sign up for a Mailgun account: Click here to sign up for your 30 day free trial.2. Add and verify your domain
Add a domain you own and verify it by setting up the DNS records Mailgun provide (SPF and DKIM) with your DNS provider. Go to Domain Verification Walkthrough for a step-by-step guide on how to do this.Note: If you do not own a domain you can use the provided sandbox domain for testing.
3. Choose how to send (SMTP or API)
Mailgun gives you the choice to send email via SMTP or our HTTP API. Choose which one is best for you.
Send with SMTP Credentials | Send with API Key |
---|---|
Open protocol with large environment | Easy to use interface |
Flexible with existing applications | Language bindings |
Better scaling |
4. Get credentials
In order to send via our HTTP API you will need your API key, and in order to send via SMTP you will need your SMTP user and password. See the article, Where can I find my API key and SMTP credentials? for details.5. Choose a language
Now you are ready to send email!