Articles on: Getting Started

Using Google Workspace, Gmail or G Suite for SMTP

Prerequisites


  • A Gmail or Google Workspace account
  • Two-Factor Authentication enabled on your Google account
  • Access to the application where you want to configure SMTP



Step 1: Enable Two-Factor Authentication


  1. Go to Google Account
  2. Select Security from the left-hand menu
  3. Under "How you sign in to Google," select 2-Step Verification
  4. Follow the on-screen instructions to enable it



Step 2: Generate an App Password


  1. Go to the App Passwords page
  2. Sign in to your Google account if prompted
  3. Enter a name for the password (e.g. WP Compress or SMTP)
  4. Click Create
  5. Copy the 16-character password that appears


When Google displays the password, it shows spaces between each group of 4 characters. Enter it without spaces when configuring your SMTP settings.



Step 3: Configure SMTP Settings


Use the following settings in your application:


Setting

Value

SMTP Server

smtp.gmail.com

Port

587 (TLS) or 465 (SSL)

Username

Your full Gmail address (e.g. yourname@gmail.com)

Password

The 16-character app password from Step 2


Port 587 with TLS is recommended for most applications.



Troubleshooting


If you cannot find the App Passwords option, confirm that 2-Step Verification is fully enabled on your account. The option will not appear until 2FA is active.


  • Authentication errors — confirm there are no spaces in the app password
  • Connection refused — check that your application supports TLS or SSL and matches the port used
  • Sending limits — standard Gmail accounts are limited to ~500 emails per day; Google Workspace accounts allow up to ~2,000

Updated on: 03/02/2026

Was this article helpful?

Share your feedback

Cancel

Thank you!