Skip to content

SMTP Configuration

Configure SMTP server for email delivery.

SMTP (Simple Mail Transfer Protocol) allows the system to send emails through any mail server. This is the most flexible option and works with custom servers, Gmail, Office 365, or any email provider that supports SMTP.

Navigation: Settings → Email → SMTP (after selecting SMTP as provider)

Prerequisites

Before configuring SMTP, you need:

  • SMTP server address (e.g., mail.company.com)
  • Port number (typically 587 or 465)
  • Username (usually your email address)
  • Password (application password, not account password)
  • TLS/SSL encryption preference

SMTP Configuration Settings

Server Address

SMTP Server Hostname

The address of your mail server:

  • Example: smtp.gmail.com (Gmail)
  • Example: smtp.office365.com (Office 365)
  • Example: mail.company.com (Company server)
  • May be domain or IP address

Port Number

SMTP Port

The port your server uses:

  • 587 - TLS/Explicit TLS (recommended)
  • 465 - SSL/Implicit SSL (older, secure)
  • 25 - Unencrypted (not recommended)
  • Custom - If using non-standard port

Best practice: Use 587 with TLS encryption.

Authentication

Username

Usually your email address:

  • Example: admin@company.com
  • Example: user+appname@gmail.com
  • Ask mail server administrator if unsure

Password

Your account password:

  • For Gmail: App password (not account password)
  • For Office 365: Standard password
  • For Company server: Provided by IT
  • Never share -store securely

⚠️ Security Note: Use application-specific passwords when available instead of account password.

Encryption

TLS/SSL Settings

How to encrypt communication with server:

  • TLS (Recommended) - Port 587, upgrade to encrypted
  • SSL - Port 465, immediate encryption
  • None (Not recommended) - Unencrypted connection

Typical Configuration: - Port: 587 - Encryption: TLS - Requires: Username & Password

Provider-Specific Configurations

Gmail via SMTP

Server Address: smtp.gmail.com Port: 587 Encryption: TLS Username: Your Gmail address Password: Gmail App Password

Steps: 1. Create App Password in Google Account 2. Use App Password (not account password) 3. Enable Less Secure App Access (if not using App Password)

Office 365 via SMTP

Server Address: smtp.office365.com Port: 587 Encryption: TLS Username: Your Office 365 email Password: Your Office 365 password

Requirements: - Modern Authentication enabled (typical) - May require MFA bypass (app password)

Company/Custom Server via SMTP

Server Address: (from IT department) Port: (from IT, typically 587) Encryption: (from IT, typically TLS) Username: (from IT) Password: (from IT)

Contact IT support for configuration details.

Configuring SMTP

Step-by-Step Setup

  1. Settings → Email → Email Settings
  2. Select SMTP as provider
  3. Save to see SMTP configuration options
  4. Settings → Email → SMTP Configuration

Enter SMTP Details

  1. Server Address
  2. Enter SMTP server hostname
  3. Example: smtp.gmail.com

  4. Port Number

  5. Enter port number
  6. Example: 587

  7. Encryption

  8. Select TLS or SSL
  9. Recommended: TLS with port 587

  10. Username

  11. Enter SMTP username
  12. Usually email address

  13. Password

  14. Enter SMTP password
  15. For Gmail: App password (not account password)
  16. For Office 365: Can be account password

  17. From Address

  18. Email address shown as sender
  19. Must match configured account
  20. Example: noreply@company.com

  21. Save

Test Configuration

  1. Click Test SMTP Connection
  2. System attempts to:
  3. Connect to server
  4. Authenticate
  5. Send test email
  6. Wait for result message
  7. Success indicates "Connection successful"

If Test Fails

Error Cause Solution
Connection refused Wrong server/port Verify server address and port
Authentication failed Wrong credentials Verify username and password
Encryption error Wrong encryption type Try different TLS/SSL setting
Timeout Server not responding Check firewall, try different port
Gmail error Missing app password Use app password, not account password

Security Best Practices

Password Management

  • ✅ Use app/application password when available
  • ✅ Don't use account password
  • ✅ Change passwords regularly
  • ✅ Use strong passwords (20+ characters)
  • ✅ Store password securely
  • ✅ Never commit password to version control
  • ✅ Use environment variables for sensitive data

Encryption

  • ✅ Always use TLS or SSL encryption
  • ✅ Never use unencrypted (port 25)
  • ✅ Use port 587 (TLS) over 465 when possible
  • ✅ Verify certificate validity
  • ✅ Monitor for certificate expiration

Access Control

  • ✅ Limit who can change email settings
  • ✅ Use dedicated service account
  • ✅ Don't use personal email account
  • ✅ Rotate credentials periodically
  • ✅ Audit who made configuration changes

Troubleshooting SMTP

Emails Not Sending

Check: 1. Email Settings has SMTP selected 2. SMTP configuration is complete 3. Test connection successful 4. Check Email Queue for errors 5. Verify credentials are correct

Try: - Send test email - Review email logs - Check mail server is running - Verify network connectivity

Authentication Failures

Gmail: - Using app password (not account password)? - Is 2-factor authentication enabled? - Is Less Secure App Access allowed?

Office 365: - Is modern authentication enabled? - Do you have MFA? Use app password if needed. - Is your account licensed for email?

Company Server: - Contact IT for account verification - Confirm username format (user@domain or domain\user) - Verify password hasn't expired

Slow Email Delivery

Check: - Server response time - Network bandwidth - Email queue size - Batch sending interval - Email rate limits

Optimize: - Use batch sending instead of immediate - Reduce email rate limit if overwhelming server - Check server logs for bottlenecks

Failed Connections

Firewall Issues: - Verify firewall allows outbound SMTP - Check if port is blocked - Try alternate port (if available) - Check with IT for firewall rules

Network Issues: - Verify internet connectivity - Check DNS resolution - Try alternate mail server (if available) - Check network cables

SMTP Sending Process

How SMTP Works

  1. Connection - Register connects to SMTP server
  2. Authentication - Logs in with username/password
  3. Compose - System builds email message
  4. Send - Transmits email to server
  5. Receipt - Server acknowledges receipt
  6. Delivery - Server delivers to recipient

Email Queue

If SMTP unavailable: - Email placed in queue - Retried based on retry policy - Eventually sent or failed after max attempts - No data loss

Failed Email Handling

When email fails: 1. Check error in Email Queue 2. Diagnose issue (see Troubleshooting) 3. Fix problem 4. Retry failed emails 5. Verify success

Monitoring SMTP

Email Logs

View recent SMTP activity:

  1. Settings → Email → Email Settings
  2. Click View Email Logs
  3. Filter by:
  4. Date range
  5. Status (Sent, Failed, Retrying)
  6. Recipient
  7. Review for issues

Success Metrics

Monitor: - Successful deliveries - Failed attempts - Retry count - Delivery time - Bounce rate

SMTP Best Practices

  • ✅ Use TLS encryption (port 587)
  • ✅ Test immediately after configuration
  • ✅ Use app passwords (not account password)
  • ✅ Monitor email queue regularly
  • ✅ Review logs for failures
  • ✅ Use dedicated service account
  • ✅ Verify SPF/DKIM records (if domain owner)
  • ✅ Keep credentials secure
  • ✅ Update passwords periodically
  • ✅ Document configuration for support