It had been a while that I owned my domain and was wondering if I could switch
all my email communication to a custom email address firstname.lastname@example.org.
Apart from owning the domain, the only requirement which remains is the that of an
MX (Mail Exchange) server which can route my emails for me. This is pretty handily done via
services like GSuite and Outlook
but I am not in a stage to shell out a few bucks for a custom email address. This
is when Mailgun enters the scene with its free offering of 10000 e-mail transactions
per month which sounds more than enough.
Here are the steps for anybody seeking solution to a similar problem.
Get a domain name from a domain registrar like
Namecheap. There is
no way you can get this for free (legally at least).
After signing up for
Mailgun (you might need to go through an activation process
with the customer care explaining your need), you must add a new custom domain
and make appropriate entries. Here is part of the
Zone File which contains
the Resource Records (
RR) to be managed.
; MX Records @ 3600 IN MX 10 mxb.mailgun.org @ 3600 IN MX 10 mxa.mailgun.org ; TXT Records @ 3600 IN TXT "v=spf1 include:mailgun.org ~all" <YOUR_DOMAIN_KEY_HOST> 3600 IN TXT "k=rsa; <YOUR_RSA_KEY>"
YOUR_RSA_KEY are available in the
dashboard. Most Domain registrars provide a comfortable GUI interface to add
Setup a new Route which in simple words means directing your new email id to an existing one.
A sample rule is:
match_recipient("email@example.com") forward("firstname.lastname@example.org") priority 10
This will forward all mails to “email@example.com” to “firstname.lastname@example.org”.
With this, you have successfully setup to receive emails at a custom domain.
To allow sending email, you need to setup custom SMTP credentials under your Mailgun domain. See How do I start sending email.
Gmail allows you to add custom emails to your account which you can send e-mail as right within Gmail itself. See Check email from other accounts with Gmail.
The settings needed are:
SMTP Server: smtp.mailgun.org PORT: 587 (TLS) Username: email@example.com Password: <Same as used during setting up SMTP credentials in Mailgun>
You should receive a verification email at the account where you chose to forward
your emails (
firstname.lastname@example.org) before you start sending emails as
Voila! Start sending emails around, send me one at email@example.com!
If you see mistakes or want to suggest changes, please create issues or revisions against source.