SMTP test connection error - Email sender connection invalid.: Cannot connect to SMTP server: smtp.office365.com, as: , message: failed to connectIssue Even though the tokens are available, upon performing a test connection you notice the below error. Email sender connection invalid.: Cannot connect to SMTP server: smtp.office365.com, as: <user name>, message: failed to connectReleaseAll releasesCauseThis is caused when user who fetched the token logged in with SSO and upon clicking the "Authorize email account access" the SSO session within the browser is used and the token will be fetched as the logged user.ResolutionNavigate to Manage tokens table and delete the existing refresh and access tokens. Now log in into the instance as a local admin (non SSO user) in an incognito window. Open the SMTP account and click on "Authorize email account access" you will be navigated to a Microsoft URL and are required to provide credentials. Now log in using the account you specified in the username field of the SMTP account form in the instance This user/account should be capable of fetching the tokens. If you are not able to fetch the tokens as this user, you will need to work with your Azure admin to fix it. Once the tokens are fetched using this account, the test connection will be successful.