Host names and ports for connecting the Email package to Microsoft Outlook, Gmail, Yahoo, and MSN mail servers.
| Server | For reading or retrieving emails | For sending emails |
| Microsoft Outlook/Microsoft Office 365 | Host:
outlook.office365.comPort:
|
Host: outlook.office365.com,
Port: Host: Port: |
| Gmail | Host:
imap.gmail.comPort:
|
Host:
smtp.gmail.comPort:
|
| Yahoo | Host:
imap.mail.yahoo.comPort:
|
Host:
smtp.mail.yahoo.comPort: |
| MSN | Host:
imap-mail.outlook.comPort:
For POP3: Host: Port: |
Host:
smtp-mail.outlook.comPort: |
The Email package supports nonstandard ports in the range of 1 through 65535 for the SMTP server.
Additional configuration for Gmail and Yahoo
Google no longer supports less secure apps, which let you sign in with only a username and password. If you use a Gmail account to automate an email-related task, you can grant access to third-party applications by using an app password. Use an app password when the application does not support Sign in with Google. App passwords work only with accounts that have 2-Step Verification turned on. As a best practice, use OAuth 2.0 authentication to access G Suite account data.
For more information on how to generate an app password for Gmail, see Generate and use app passwords for Gmail.
If you use a Yahoo account to automate an email-related task, generate an app password on the Yahoo account security page. Then use the app password and your email address to sign in to your email account.
For more information on how to generate an app password for Yahoo, see Generate and use app passwords for yahoo.