Manual Salesforce Logging of Emails with Attachments for Gmail

Modified on Mon, 18 Dec 2017 at 11:04 AM

This guide will walk your Google administrator through how to set up your G Suite server to filter your outgoing emails without attachments to automatically be forwarded to your unique Email to Salesforce Address. Emails that are forwarded to your unique Email to Salesforce Address will be logged to the appropriate records in Salesforce. On the other hand, users outgoing emails that contain attachments will be forwarded to themselves and send to the "Log this Email with Attachments" email folder in Gmail. Users will be able to utilize Lightning for Gmail to log the emails with attachments to the appropriate records in Salesforce.


Create Gmail Rule for Emails without Attachments

We will create a Gmail rule to forward all incoming emails without attachments from yourself to be forwarded to your unique Email to Salesforce Address. 


Navigate to your Gmail settings (gear icon).



Click Create a new filter hyperlink in the Filters and Blocked Addresses tab.



Email Filter Settings

Enter your company email address that you use in Gmail to email leads and contacts in the From section. Only emails without attachments received from the email address you specify can be forwarded to your unique Email to Salesforce Address.


Please note: This email address should be the same email address that you have entered in the My Acceptable Email Addresses list in Salesforce.


From the Filter Creation Page:

  • Enter your company email address that you use in Gmail in the From section.

  • Select less than in the Size filter.

  • Type 1.

  • Select KB.

  • Click Create filter with this search hyperlink.



Email Forwarding Settings

Enter your unique Email to Salesforce Address that was automatically generated in Salesforce. Any emails without attachments that meet the rule criteria will be forwarded to this email address.


Please note: Any emails that are forwarded to this email address will also be forwarded to your Salesforce Org and related to Leads, Contacts, Opportunities, and Accounts object.


From Filter Creation Page:

  • Select Skip the Inbox (Archive it). Any emails that meet the rule criteria will be archived. 

  • Select Forward it to: and choose your forwarding address that you have just added to your Gmail Account. 

  • Click Create filter



Create Gmail Rule for Emails with Attachments

We will create an inbox folder name "Log this Email with Attachments" in Gmail. Afterward, we will create another Gmail rule to forward all incoming emails that are from ourself and contains an attachment to this folder. Once this step is completed, users will be able to navigate to this folder and manually log their outgoing emails with an attachment to Salesforce.


In the Gmail application Home tab:

  • Right click on the Categories folder in Inbox.
  • Select Create new label hyperlink.
  • Name the folder appropriately.



Navigate to your Gmail settings (gear icon).



Click Create a new filter hyperlink in the Filters and Blocked Addresses tab.



Email Filter Settings

Enter your company email address that you use in Gmail to email leads and contacts in the From section. Only emails with attachments received from the email address you specify can be forwarded to your Emails with Attachment email folder.


Please note: This email address should be the same email address that you have entered in the My Acceptable Email Addresses list in Salesforce.


From the Filter Creation Page:

  • Enter your company email address that you use in Gmail in the From section.

  • Select Has attachment.

  • Click Create filter with this search hyperlink.



Email Forwarding Settings

Select your Emails with attachments folder that you just created in Gmail. Any emails that meet the rule criteria will be forwarded to this email folder.


From Filter Creation Page:

  • Select Apply the label

  • Select Emails with Attachment folder. Any emails that meet the rule criteria will be sent to this folder.

  • Click Create filter



How to use Lightning for Gmail to Manually Log Emails with Attachments to Salesforce

Users can use Lightning for Gmail to log emails with attachment to the appropriate records in Salesforce. 


  • Click into your Emails with Attachments email folder.
  • Click into the specific email with attachments.
  • Navigate to Lightning for Gmail side panel.
  • Select the Up Arrow icon (Contact, Opportunity, Account, etc.) to log the email to the Salesforce record.



You have completed the steps to automatically forward all outgoing emails that does not contain an attachment to your Unique Email to Salesforce Address. You have also completed the steps to automatically forward all outgoing emails that does contain an attachment to your user's appropriate email folder in Gmail. Afterward, users can utilize Lightning for Gmail to log these emails to the appropriate record in Salesforce.