ScanSkill
Sign up for daily dose of tech articles at your inbox.
Loading

Use Gmail With Custom Domain For Free Using Cloudflare

Use Gmail With Custom Domain For Free Using Cloudflare
Use Gmail With Custom Domain For Free Using Cloudflare

In this tutorial, we’ll set up Gmail with custom domain so that you can send/receive emails entirely for free.

If you have a personal/business website, creating a free custom domain email address is essential. However, most services charge a subscription fee for allowing you to host emails with your domain. Even google’s plan is not free at all like before.

Prerequisites

  • Domain name (I have hosted the domain name on Cloudflare)
  • Regular Gmail Account

Configure Custom Domain Email Address on Cloudflare

First, we need to create a custom email address using our email hosting (or domain hosting). E.g. contact@yourdomain.com.np. You can use free email forwarding services to create a custom email address.

But If you’re using Cloudflare as a DNS service, you can use their free email service which is currently a beta version.

As I’m using Cloudflare as a DNS service:

1. Custom Email

  • Go to email on the Cloudflare dashboard and create address.
  • Enter the custom email address you want to create.
  • Add destination email address, in my case I’ve added my Gmail address. (This means all emails to the custom email addresses will be forwarded to your main Gmail address)

Cloudflare will send a verification link to your destination email address. Verify the email address to activate the email routing.

2. Add DNS Records

Now, after creating a custom email address and verifying the destination email address, you need to set up MX and TXT records to your DNS. This can be done automatically by clicking Add records automatically.

Note: if there are other MX records already configured in DNS, Cloudflare will ask you if you wish to delete them. If you don’t delete existing ones, email routing won’t be configured.

3. Test

Send an email from another mail address to the custom mail address you set up above. You will see that email to your main address (my_account@gmail.com).

Also Read:

Configure SSL on Ubuntu Server Using Certbot

Send with custom email address in Gmail using SMTP (Gmail with custom domain)

You have successfully set up a custom email and configured it to receive all emails sent to custom mail to your main Gmail address.

In this section, we’ll be configuring Gmail with custom domain so that we’ll be able to reply from your custom email domain.

Step-1: Generate App Password

myaccount.google.com
  • Enter your password and click Next.
  • Click on Select app and select Other
  • Enter your app name whatever you want (in my case, I used ‘contact@mydomain.com.np’ as my app name) and click Generate. Copy or save the password generated. We’ll use this later.

Go back to Gmail and follow the steps:

Step-2: Configure Gmail SMTP Server

  • Gmail settings > Accounts and Import
  • Click on Add another email adddress. Enter custom email address created before (contact@yourdomain.com.np). Uncheck Treat as an alias checkbox. Doing so will send all your emails using your Gmail address.
  • Go to Next Step and configure:
    • SMTP Server: smtp.gmail.com
    • Username: your full Gmail address (main Gmail address) (yourmail@gmail.com)
    • Password: password generated in step-1 (Important)
    • Port: 587(TLS) or 465(SSL)
  • Click on Save Changes. Then a confirmation email will be sent to your mail address with a confirmation code. Enter that code and click Verify. Or you can click the link sent by mail.
Gmail verification

You have successfully verified your custom email address and setup with Gmail. You can send/reply with your custom domain using Gmail.

Further,

You can make the custom email address a default mailing address:

Step-3: Test

If everything works, you’re all done configuring Gmail with custom domain.

Conclusion

In this way, we have configured DNS and Gmail in a way so that emails sent to your domain email address will show up in your Gmail mailbox, and also you can send or reply from your custom domain email address.

If you still have questions about how to configure Gmail with custom domain name, ask us in the comments!

Also, check out my other articles: Add a Custom Domain to Free Heroku App Using Cloudflare and Configure Postfix with Gmail SMTP on Ubuntu (22.04 | 20.04 | 18.04).

Sign up for daily dose of tech articles at your inbox.
Loading