The SMTP host, port and login for every major email provider, checked October 2026. Pick your provider for the details and the common mistakes, or test your settings in FormSMTP and send email from any website with them.
Quick reference
| Provider | SMTP host | Port | Username |
|---|---|---|---|
| Gmail | smtp.gmail.com | 465 (SSL) or 587 (STARTTLS) | Your Gmail address |
| Google Workspace | smtp.gmail.com | 465 (SSL) or 587 (STARTTLS) | Your full Workspace address |
| Outlook.com / Hotmail | smtp-mail.outlook.com | 587 (STARTTLS) | Your Outlook.com address |
| Microsoft 365 | smtp.office365.com | 587 (STARTTLS) | Your full mailbox address |
| Zoho Mail | smtp.zoho.com | 465 (SSL) or 587 (STARTTLS) | Your full Zoho address |
| iCloud Mail | smtp.mail.me.com | 587 (STARTTLS) | Your full iCloud address |
| Yahoo Mail | smtp.mail.yahoo.com | 465 (SSL) or 587 (STARTTLS) | Your full Yahoo address |
| Amazon SES | email-smtp.<region>.amazonaws.com | 587 or 2587 (STARTTLS), 465 or 2465 (SSL) | SES SMTP username |
| Brevo | smtp-relay.brevo.com | 587 (STARTTLS), 465 (SSL) or 2525 | SMTP login shown in Brevo |
| SendGrid | smtp.sendgrid.net | 587 (STARTTLS), 465 (SSL) or 2525 | apikey |
| Resend | smtp.resend.com | 465 or 2465 (SSL), 587 or 2587 (STARTTLS) | resend |
| Mailgun | smtp.mailgun.org | 587 (STARTTLS), 465 (SSL) or 2525 | Domain SMTP login, e.g. postmaster@mg.yourdomain.com |
| Hostinger Email | smtp.hostinger.com | 465 (SSL) or 587 (STARTTLS) | Your full email address |
| Spacemail | mail.spacemail.com | 465 (SSL) | Your full email address |
Gmail SMTP settings
| Host | smtp.gmail.com |
| Port | 465 (SSL) or 587 (STARTTLS) |
| Username | Your Gmail address |
| Password | App Password (needs 2-Step Verification) |
About 500 recipients a day.
Step-by-step: use Gmail SMTP for a website contact form
Google Workspace SMTP settings
| Host | smtp.gmail.com |
| Port | 465 (SSL) or 587 (STARTTLS) |
| Username | Your full Workspace address |
| Password | App Password (needs 2-Step Verification) |
About 2,000 recipients a day. Admins can disable App Passwords.
Step-by-step: use Google Workspace SMTP for a website contact form
Outlook.com / Hotmail SMTP settings
| Host | smtp-mail.outlook.com |
| Port | 587 (STARTTLS) |
| Username | Your Outlook.com address |
| Password | OAuth only |
Password sign-in was removed on September 16, 2024, so password-based tools (including FormSMTP) can’t use it.
Step-by-step: use Outlook.com / Hotmail SMTP for a website contact form
Microsoft 365 SMTP settings
| Host | smtp.office365.com |
| Port | 587 (STARTTLS) |
| Username | Your full mailbox address |
| Password | Mailbox password |
Needs Authenticated SMTP enabled. Password SMTP AUTH is off by default from end of December 2026.
Step-by-step: use Microsoft 365 SMTP for a website contact form
Zoho Mail SMTP settings
| Host | smtp.zoho.com |
| Port | 465 (SSL) or 587 (STARTTLS) |
| Username | Your full Zoho address |
| Password | Password, or app-specific password with 2FA |
Use your region’s host: smtp.zoho.eu, smtp.zoho.in, smtp.zoho.com.au… Organization accounts may use smtppro.zoho.*.
Step-by-step: use Zoho Mail SMTP for a website contact form
iCloud Mail SMTP settings
| Host | smtp.mail.me.com |
| Port | 587 (STARTTLS) |
| Username | Your full iCloud address |
| Password | App-specific password |
Generate the password at account.apple.com.
Yahoo Mail SMTP settings
| Host | smtp.mail.yahoo.com |
| Port | 465 (SSL) or 587 (STARTTLS) |
| Username | Your full Yahoo address |
| Password | App password |
Generate it in Yahoo Account Security.
Amazon SES SMTP settings
| Host | email-smtp.<region>.amazonaws.com |
| Port | 587 or 2587 (STARTTLS), 465 or 2465 (SSL) |
| Username | SES SMTP username |
| Password | SES SMTP password |
SMTP credentials are not AWS access keys. New accounts start in the sandbox.
Step-by-step: use Amazon SES SMTP for a website contact form
Brevo SMTP settings
| Host | smtp-relay.brevo.com |
| Port | 587 (STARTTLS), 465 (SSL) or 2525 |
| Username | SMTP login shown in Brevo |
| Password | SMTP key (not an API key) |
The login may be your account email or an @smtp-brevo.com address.
Step-by-step: use Brevo SMTP for a website contact form
SendGrid SMTP settings
| Host | smtp.sendgrid.net |
| Port | 587 (STARTTLS), 465 (SSL) or 2525 |
| Username | apikey |
| Password | API key with Mail Send permission |
The username is the literal word apikey.
Step-by-step: use SendGrid SMTP for a website contact form
Resend SMTP settings
| Host | smtp.resend.com |
| Port | 465 or 2465 (SSL), 587 or 2587 (STARTTLS) |
| Username | resend |
| Password | Resend API key |
Requires a verified domain.
Step-by-step: use Resend SMTP for a website contact form
Mailgun SMTP settings
| Host | smtp.mailgun.org |
| Port | 587 (STARTTLS), 465 (SSL) or 2525 |
| Username | Domain SMTP login, e.g. postmaster@mg.yourdomain.com |
| Password | Password set for that login |
EU-region domains use smtp.eu.mailgun.org.
Step-by-step: use Mailgun SMTP for a website contact form
Hostinger Email SMTP settings
| Host | smtp.hostinger.com |
| Port | 465 (SSL) or 587 (STARTTLS) |
| Username | Your full email address |
| Password | Mailbox password |
Titan Email mailboxes use Titan’s own host.
Step-by-step: use Hostinger Email SMTP for a website contact form
Spacemail SMTP settings
| Host | mail.spacemail.com |
| Port | 465 (SSL) |
| Username | Your full email address |
| Password | Mailbox password |
Spaceship’s email hosting.
SMTP ports: 465 vs 587 vs 25 vs 2525
| Port | Encryption | Use it for |
|---|---|---|
465 | Implicit TLS (“SSL”) from the first byte | Sending from apps and websites. In FormSMTP, turn SSL on. |
587 | STARTTLS: starts plain, then upgrades | Sending from apps and websites. In FormSMTP, leave SSL off; the connection still upgrades to TLS. |
2525 | STARTTLS, unofficial | A fallback some sending services offer when 587 is blocked. |
25 | Optional STARTTLS | Server-to-server relay. Often blocked by hosts and ISPs; avoid it for submission. |
FAQ
Should I use port 465 or 587?
Both are encrypted. Port 465 starts TLS immediately (often labelled SSL); port 587 connects in plain text and upgrades with STARTTLS. Use whichever your provider lists first. If one is blocked by your network or host, try the other.
Why is my normal password rejected?
Many providers no longer accept your account password for SMTP. Gmail, iCloud and Yahoo need an app password, Zoho needs one when two-factor sign-in is on, and sending services like SendGrid, Brevo and Resend use an SMTP key or API key instead. Personal Outlook.com accounts no longer allow password sign-in for SMTP at all.
What is port 25 for?
Port 25 is for server-to-server mail transfer. Many hosting and cloud providers block it outbound, so websites and apps should submit mail on 465 or 587.
How do I test SMTP settings without writing code?
Create a free FormSMTP project, pick your provider so the host and port fill in, enter your login and click Test connection. It shows the exact error from your provider if something is wrong.