on Technology

Removing the GMail "On Behalf Of" Sender Header

Like many of you, I have several email accounts and while using GMail as my primary email client would be nice, one of the things that has kept me from doing so is the annoying "On Behalf Of" that the GMail SMTP servers add to outgoing email. Some of the accounts are work related and the "On Behalf Of" comes across to me as unprofessional.

GMail On Behalf Of

That "On Behalf Of" part is caused by the Sender: header that GMail's SMTP servers add:

Having your personal GMail address show up looks totally unprofessional and prevents you from being able to keep your personal email, uh, well, personal. Unfortunately, Google has already said it's part of their SMTP server specs, so they won't change it.

For a long time, your only option was to use a desktop email client like Outlook or Thunderbird to send email using your own domain's SMTP server. However, this meant accessing your GMail account using IMAP/POP and basically defeated the purpose of the web client (unless you didn't mind switching between the web and desktop client).

When Google offered GMail for Domains (now called Google Apps for Domains), I eagerly set up a free account using one of my domains and tested to see if email sent still included the Sender header. Sadly it did and I abandoned the idea of using GMail as my primary email client.

A few days ago I accidentally discovered that now both the standard GMail and Google Apps for Domains have the ability to specify your own SMTP server when you add an external email address to your GMail account. (Here's the announcement from a few months ago on Google's Blog.) This means you can receive email from you@yourdomain.com and also reply to emails from within GMail as you@yourdomain.com and the receiver won't know that you're using GMail!

Here's how to get this set up:

Login to GMail and click Settings at the top right. Then click the Accounts and Import tab:

GMail Settings - Accounts and Import

Now make sure the "Reply from the same address the message was sent to" is selected and click "Send mail from another address" to add your external email account.

GMail - Send mail from another address

Fill in the name you want to show up when you send email from this account. This will probably be your name, but it might also be something like "Company Support" or "Sales". Now enter your full external email address in the second box and then click Next Step.

GMail - Add another address - Step 1

On the next screen, select the second option box, "Send through SMTP servers" and fill in the SMTP Server, Username, and Password fields. When you click Add Account, Google will try connecting to the SMTP server using the credentials you supplied. If it successfully connects, you'll be brought back to the Accounts and Import tab with your new account added. Otherwise, Google will display the error it had when trying to verify the SMTP connection details.

GMail - Add another address - Step 2

Now you should see the new account listed on the Accounts and Import tab, along with a note at the bottom showing that email will be sent using the SMTP server you specified:

GMail - New account listed on Accounts and Import tab

Now, you can send and receive email using this external account and the receiver won't see that annoying "On Behalf Of" message! Your GMail address won't even be visible in the email headers if they choose to view the email source (they'll see that the email was routed through a Google server, but Google is well known enough that they probably won't care).

Leave a Reply for Raam Cancel Reply

Write a Comment

Comment

18 Comments

  1. Wow – I was not aware of this although I have been using my personal Gmail to send and receive from all sorts of accounts.

    When I sent you a mail this evening did it have that ‘on behalf of’ message? I’ve truly never noticed it.

    • Hey Ali*,

      I looked at your email and it doesn’t appear to have the “On Behalf of”. Keep in mind that not all email clients will show this “On Behalf of”. One way you can check if it will show up is by viewing the email source and looking for the Sender: header. That’s the header that some email clients display as “On Behalf of”.

      I looked at the source for the emails you sent me and I did not find the Sender: header, so you should be OK. This means you’re probably using the SMTP server for your other email accounts and NOT the GMail SMTP server.

      Thanks for stopping by! ๐Ÿ™‚

  2. Hi,

    works, but just for the standard gmail account. If you have an apps account you will not find all settings mentioned in your post, unfortunatly. Or have I made some thing wrong?

    Cheers

    • Hi Buschihh,

      The Google Apps for Domains email accounts have the same functionality. Simply go to Settings and then click the “Accounts” tab. From there, you can add an external email account and then make sure “Reply from the same address the message was sent to”. Then simply add your external account.

      Hope this helps!

  3. Hi Raam,

    I found it on an other blog. The most important thing is, to enable “Outbound relay” in the site settings under “service settings” –> “emails”. Not having enabled this you wouldn’t have โ€œSend through SMTP serversโ€ option.

    Buschihh

  4. Last Resort – I want to do the opposite of the described above, that is

    hide my Gmail account e mail address, and only show my “on behalf of” address, without the “on behalf of”.

    On behalf of is a company .com email address, so any emails go out as

    XYZ@gmail.com on behalf of “Company Name.com”, and I just want the Company Name.com

    Thanks if you can provide any help

    • Hey Mark,

      This actually describes exactly that — how to show only the On Behalf Of Address. The whole thing is, you need to configure an SMTP server in your GMail account that corresponds to the On Behalf Of address (i.e., your company’s SMTP server).

  5. Hi Raam,

    Nice post. This works perfectly with an external account hosted in other mail server. But I have the issue using a secondary gmail account set in my main gmail account. I mean, I have main@gmail.com and secondary@gmail.com, if I send an email choosing “secondary@gmail.com” from drop-down list, the header includes “main@gmail.com” in sender field.

    I have tested checking or not “Treat as an alias” field from gmail accounts settings, with the same results.

    Do you know any way to send the correct sender in this case?
    I would like to do this without login in the other account.

    Thank you for your time!
    Greets.

      • After using gmail for years and NOT having my outgoing mail from other accounts being sent as “sent on behfalf of,” gmail has now added it. (I just noticed it in a reply to from someone who sent me back the original e-mail in the thread and was shocked that he had my gmail account in there!)

        I see the work-around, but wonder if you know which e-mail clients/servers out there do NOT send your e-mail out from other accounts as “on behalf of.” I have looked all over the web, but no one really seems to address this particular issue.

    • Are you sure about that? I’m still able to add an account under `Settings โ†’ Accounts` and then configure SMTP servers to send the email (which allows me to send emails through my own server).

  6. This is not working. Google still modified sent email headers to make all your communication traceable (also for the government). All your identities can be traced into google account. The modified header data is Sender and Devivered-To. Many implementations of mail servers treat these fields in higher priority over others, causing the replies by senders going to google address! This happened to me many times.
    The only way to disinfect this would be to have a script on your own server to remove google crap. Any volounteer?

  7. Problem… you’re not actually sending the email through Gmail servers… so you are still using your own server resources. The goal (for me) would be to send from gmail as me@mydomain so that I can leverage the gmail servers and not my own servers…

  8. Hi Mr.Dev
    I am not able to find the above settings in Gmail->settings->Accounts and Import.

    I want to remove “On behalf of “. kindly Help me on this.

    Thank you.

Webmentions

  • I’m Looking For a New Email Host | DesertFlood September 18, 2015

    […] header anytime you send a message from an alternate email address. You can prevent this (setup instructions) but itโ€™s a bit clunky and requires you to have an external SMTP […]

  • Raam Dev September 18, 2015

    New on Solid State Raam: Removing the GMail "On Behalf Of" Sender Header: http://tr.im/HvvK

  • Further Reading