How Do I Set Up Email Forwarding to Gmail Account?

October 18, 2013 21.5k views
Hi, I've tried many of the answers on the forum here but am not finding anything that works. I registered my domain name through and it's pointed to my droplet. My blog works fine, but now I'm trying to set it up so will auto-forward to my gmail address. Can anyone help or point me in the right direction? Thanks
11 Answers

Digital Ocean doesn't provide a service like the one you're looking for -- but there is a way to use NameCheap's services and still have your name point to your droplet.

The consequence of using NameCheap's name servers instead of your own is that things like PTR records will be handled at NameCheap, not here on Digital Ocean. But ths is probably what you want. Also, f your IP address for your droplet changes for any reason, you'll need to go to NameCheap to update it. The same is true for adding subdomains, etc.

  • Go to the DigitalOcean DNS panel, and look up the IP address of your droplet. Keep this up for reference.
  • Go to NameCheap, and select "Transfer DNS Back to Us"
  • Go to NameCheap, and select "All Host Records"
  • Copy records over from the DNS page on Digital Ocean
    • For example, hostname '@' should have the IP address of your server, and it should be an 'a' record.
    • Don't include the Digital Ocean 'ns' entries.

You should now be able to forward mail using NameCheap, and access to your host name should point to the droplet.

EDIT: Any idea how to do second-level indentation?

EDIT 2: Oh, the markdown's not working properly. ..anyways, the last two list items above should be indented.

EDIT 3: Also, note that the service provided by NameCheap is only a forwarding service, you won't be able to set it up in gmail as a proper email address.

You're not talking about Google Apps, right? Assuming you're not, you would do that through NameCheap's control panel.
Or... you can POP your emails into your Gmail Inbox and even be able to send mail as from your Gmail web interface.
NameCheap used to give me the option to use their free forwarding, but since I now have my DNS settings running through DigitalOcean, I no longer have that option since it all runs through here. I just want to be able to have any emails sent to forward to my gmail address. Right now, anyone that sends an email gets it bounced back since I have no mail servers set up.
You'll have to install a POP server. Check out Dovecot Server | Ubuntu Server Guide and set up an MX record.
This confuses me, because I have a client using GoDaddy and DigitalOcean and the email forwarding from GoDaddy works just fine, with the DNS set to DigitalOcean. Why doesn't this work for NameCheap?
Unfortunately, NameCheap doesn't offer email forwarding to its clients that use their nameservers and control panel. There's not much we can do about it on our end.

I don't know your starting setup, but you'll certainly need a mail server (MTA) with an alias entry in your domain pointing to your Gmail address. If you use postfix have a look at "man virtual" and this tutorial.

I just tried the NameCheap experiment on one of my domains. Handed control of DNS back to them, set up a forwarder, gave it a while, and sent a test that successfully forwarded to GMail. There's one downside though: GMail displays the incoming message as coming from:

John Doe via 

That "via" part is not a very professional appearance - kind of weird and off-putting for recipients. I think I'll go for the postfix setup after all.

Have another answer? Share your knowledge.