By Skylar Macromallis, CRM Consultant
Given the obvious email integration capabilities between Dynamics 365 and the rest of the Microsoft stack, when rolling out an implementation many organizations opt to switch to Exchange Online-- but what if your organization uses Gmail? Fear not, Microsoft is Google-friendly here!
Configuring Gmail for the Integration
Firstly, we will have to look at taking a look at our settings in Gmail to permit external access to the mailbox using POP3 protocol.
- From mail.google.com, navigate to Settings > Forwarding and POP/IMAP
- Select Enable POP for mail that arrives from now on and When messages are accessed with POP archive Gmail's copy.
- Click on Save Changes.
Gmail will at times block connections from third party apps. While Dynamics 365 uses built-in security features to keep data safe, it is not exempt from Google's own built-in security features. To enable this connection:
- Go to https://google.com/settings/security/lesssecureapps
- Toggle Allow less secure apps: ON
You can read more about Dynamics 365 security here.
Creating a Gmail Email Server Profile
We must next configure the Email Server Profile in Dynamics 365 to connect to Gmail. Dynamics 365 will want to use Exchange Online by default, so we must create an entirely new profile so the mailboxes can connect to Google's servers.
- Navigate to your Dynamics 365 instance using your custom URL.
- Go to Settings > Email Configuration > Email Server Profiles
- Click on + New > POP3/SMTP Server
- Type in a name, such as "Gmail"
- Input the following values:
- Incoming Server Location: pop.gmail.com
- Outgoing Server Location:
- If a personal account, enter smtp.gmail.com
- If you are using Gmail with a work account, enter mail.[yourdomain].com
- Authenticate Using Credentials Specified by a User or Queue
- Use same settings for Outgoing Yes
- Expand the Advanced tab and enter the following values:
- Incoming Port: 995
- Outgoing Port:
- If a personal account, enter 465
- If you are using Gmail with a work account, enter 110
- Click Save and Close.
Enabling Server-Side Synchronization
Server-side synchronization is the mechanism that provides the integration between Dynamics 365 and an email server. This is Microsoft's preferred method of synchronization, with the other two options (Outlook and the Email Router) being gradually phased out. To ensure that this is enabled:
- Navigate to Settings > Email Configuration > Email Configuration Settings
- Verify that Process Email Using is set to Server-Side Synchronization
- Verify that the Server Profile is populated with the Gmail Server Profile you just created. If not, change it as such.
Setting-up Mailboxes
Our final steps will be to approve our mailboxes to use the Email Server Profile we created to communicate with Google's servers.
- Go to Settings > Email Configuration > Mailboxes
- Double-click on the mailbox you would like to configure.
- Modify the following values:
- Allow to Use Credentials for Email Processing: Yes
- Enter the Gmail account credentials
- Server Profile:
- Incoming Email: Server-Side Synchronization or Email Router
- Outgoing Email: Server-Side Synchronization or Email Router
- Click on Save.
- Click on Approve Email (note that this will only work if you are an Office 365 Global Admin)
- Click on Test and Enable Mailbox
- When you are prompted to "Sync items with Exchange from this Dynamics 365 Organization only," leave the box unchecked and hit Ok.
Wait up to a minute and refresh the page. Configuration test Results should all show as Success!
Further reading:
https://technet.microsoft.com/en-us/library/dn531050.aspx
https://support.google.com/mail/answer/7104828?hl=en&ref_topic=3398031
*This post is locked for comments