Troubleshooting server-side synchronization with Gmail

Important

As documented here, starting May 30th of 2022, Gmail is ending support for apps that are configured to only use your username and password. To use server-side synchronization with Gmail, follow the steps in Connect Gmail accounts by using OAuth 2.0.

This article helps you resolve the problem that occurs when a Dynamics 365 mailbox is configured to use server-side synchronization with Gmail.

Applies to:   Microsoft Dynamics 365
Original KB number:   4493342

Symptoms

When you try to test and enable a mailbox that's configured to use server-side synchronization with Gmail, the test might fail, or the incoming emails might not be received in Dynamics 365.

Cause 1:Incorrect port configuration

If your mailbox fails to be tested and enabled, it might be due to incorrect configuration of incoming or outgoing ports. A Gmail email server profile in Dynamics 365 should use port 995 for incoming mail and port 587 for outgoing mail.

To solve this issue, verify that your email server profile is set up with port 995 for incoming emails and port 587 for outgoing emails. Enable settings from Less secure apps & your Google Account, if necessary.

Cause 2: Absence of "recent mode"

If the mailbox is tested and enabled successfully but emails aren't received in Dynamics 365, it might be because "recent mode" isn't used.

Update the Gmail email address within Dynamics 365 by including recent: at the beginning of the address. For example, change example@gmail.com to recent:example@gmail.com. For more information, see Emails aren't downloading correctly.

Third-party information disclaimer

The third-party products that this article discusses are manufactured by companies that are independent of Microsoft. Microsoft makes no warranty, implied or otherwise, about the performance or reliability of these products.