1. Home
  2. Docs
  3. Sockets
  4. Gmail

Gmail

Step 1: Install Post SMTP Plugin

Download and install Post SMTP directly from the WordPress plugin directory.

Install Post SMTP Plugin

Step 2: Activate Post SMTP Plugin

Once the plugin has been installed and activated, a prompt asks you to begin configuring it. Click the setting menu

Activate Post SMTP Plugin

Step 3: Start The Wizard

After providing your name and email address in the appropriate fields, you will be able to start the process by clicking the “Start the wizard” button

Start The Wizard

Step 4: Gmail SMTP Server

The plugin will shortly connect with the Gmail SMTP server automatically. Then, select the following option by clicking the Next button

Gmail SMTP Server

Now Select Gmail API and click on Next

Select Gmail API

Step 5: Google API Console has the Gmail API

In Step 4, you need to select Gmail API, and then you need to choose Google Cloud Console

https://console.cloud.google.com/
Google API Console has the Gmail API

Step 6: On Cloud Console, Create A New Project

On Cloud Console

Add the Project name and organization and create the project

Add the Project name and organization

Step 7: Enable the Cloud Console API

Select Enable APIs and Services tab

Enable the Cloud Console API

Select the Gmail API

Select the Gmail API

Click Enable

Click Enable

Navigate to the OAuth Consent screen and select User, type “Internal,” and Click Create

OAuth Consent screen

Now add the App Name and Emails, and then click SAVE AND CONTINUE

add App Name and Emails

Now, set 3 discretionary (Scopes) and click on SAVE AND CONTINUE

set 3 discretionary

Step 8: Create a Credential Type

In the following step, you will make SMTP credentials. Choose User Information

Choose User Information

Click on CREATE CREDENTIALS, then OAuth client ID

Note down the Client ID and Secret, then put them in the right places in the Setup Wizard for the plugin (step 8). Click Web Client 1 to see your Client ID (OAuth name)

CREATE CREDENTIALS

Navigate to the website and Copy the Authorized URL from Post SMTP Step 5

Navigate to the website and Copy the Authorized URL

Paste the URLs in the Below screen

Paste the URLs

Copy the Client ID and Client Secret

Copy the Client ID

Paste the Client ID and Client Secret into the right fields

Paste the Client ID

If you want to use the additional notification feature, then you can select the SLACK or CHROME option from the drop-down; if not, then click on next

additional notification feature

Now, click on FINISH

click on FINISH

Step 9: Create a “From Address”

Now Goto Post SMTP > Settings > Message Tab and add the email which you are using in your google cloud console

Create a “From Address”

Step 10: Grant Permission with Google

Click Grant permission with Google in your WordPress dashboard under Post SMTP Setup now

Grant Permission with Google

Select the Google Email account you wish to use and grant the app permission to access your inbox from the resulting dialog box

Google Email account

Allow the Access and proceed

Allow the Access and proceed

Step 11: Send a Test Email

At this point, we’ll double-check to make sure everything is functioning as planned. Simply enter the recipient’s email address and select the Send a Test Email option under the Actions tab

Send a Test Email
enter the recipient's email address
Send a Test Email option

This type of email should be received if the settings are all correct

type of email should be received

For more details, see the tutorial video: https://www.youtube.com/watch?v=uN_8lNv7KBo&t=7s

For External User Field: –

⦁ If you don’t have a paid account, you are unable to select internal, so select external.

⦁ Fill in the App name, User Support Email, and Developer Contact Information with the correct information & click on the save and continue button until you reach the summary tab.

⦁ Now click on Back to Dashboard.

⦁ Go to credential and click on Create a credential option & select OAuth client ID.

⦁ Select web application in the application type option.

⦁ Go back to the POST SMTP setup wizard and copy Authorized JavaScript’s origins & Authorized redirected URL.

⦁ Get back to google console and paste the Authorized JavaScript’s origins & Authorized redirected URL in their relevant field and select create.

⦁ Your client id and client secret have been generated.

⦁ After completing the above steps go to OAuth Consent Screen tab and click on publish.

⦁ Go back to the POST SMTP setup wizard and paste the client id and client secret in their relevant field.

Paste the Client ID

⦁ Click next and then click finish.


Repeat step 9. 

⦁ Click on grant permission with Google and process.

⦁ After that, click on send a test email in the POST SMTP setting and send the email.

Wrap up

You can think of an SMTP server as the digital equivalent of a postman; it either directly delivers your emails to the recipients’ inboxes or forwards them to other postmen outside of your domain. Remember that SMTP servers only handle outbound messages. For incoming emails, you’ll need either an Internet Message Access Protocol (IMAP) server or a Post Office Protocol (POP3) server.

Please visit Postman SMTP documentation if you need to help to send an SMTP email. Create an account right now, and it’s free! Or, if you already have an account and need help, chat with SendGrid’s support team!

Was this article helpful to you? Yes No

How can we help?