Skip to main content

Configuring Gmail for Basic Auth

Connect ServiceOps to Gmail using an App Password to send and receive emails without exposing your Google account password.

What is Basic Auth?

Basic Authentication is a simple authentication method that uses a username and password to verify access to an email server. For Gmail, Google requires you to use an App Password rather than your regular account password. An App Password is a 16-character code generated from your Google account that grants ServiceOps access to the mailbox without sharing your main credentials.

2-Step Verification Required

App Passwords are only available when 2-Step Verification is enabled on the Gmail account. Complete Steps 1 to 5 below before configuring ServiceOps.

Prerequisites

  • A Gmail account with 2-Step Verification enabled.
  • IMAP or POP3 must be enabled on the Gmail account before configuring it for incoming email.

Configuring Gmail for App Password

Step 1: Sign in to Gmail

Sign in to your Gmail account.

Step 2: Enable IMAP or POP3

Enable IMAP or POP3 from Gmail Settings > See all settings > Forwarding and POP/IMAP.

Step 3: Open 2-Step Verification Settings

Navigate to Manage your Google Account > Security and click 2-Step Verification.

Google Account Security tab showing 2-Step Verification option

Step 4: Start 2-Step Verification Setup

Click Get Started.

2-Step Verification setup screen with Get Started button

Step 5: Complete Verification Setup

Click Continue.

2-Step Verification confirmation screen

Enter a phone number as a backup option and click Send.

Phone number entry screen for 2-Step Verification backup

Click Turn On to enable 2-Step Verification.

Turn On button to activate 2-Step Verification

Step 6: Generate an App Password

Search for App Passwords in the Google Account search bar and open the App Passwords page.

App Passwords Visibility

The App Passwords option is available only after 2-Step Verification is enabled.

Google Account search bar showing App Passwords result

Enter an App name to identify the password (for example, ServiceOps) and click Create.

App Passwords page showing the App name field and Create button

The App Password is generated. Copy the 16-character password. You will need it in ServiceOps.

Generated App Password displayed on screen

Configuring Gmail in ServiceOps (Incoming)

Navigate to Admin > Support Channel > Emails > Incoming Email Servers and click Add Incoming Email Server.

Add Incoming Email Server form configured for Gmail Basic Auth

Enter the following details:

ParameterDescription
NameEnter the name of the email server.
EmailEnter the Gmail address used for authentication.
ProtocolSelect IMAP or POP3. The selected protocol must be enabled on the Gmail account.
Technician GroupSelect the technician group assigned to requests created via this email.
CategorySelect the category assigned to requests created via this email.
Proxy ServerSelect the required proxy server. Leave blank if ServiceOps has direct internet access.
Email ProviderSelect Other.
ServerEnter imap.gmail.com for IMAP or pop.gmail.com for POP3.
PortEnter the port number. Common values: IMAP: 993, POP3: 995.
Security TypeSelect SSL or TLS.
Email Auth TypeSelect Basic Auth.
UsernameEnter the full Gmail address.
PasswordPaste the App Password generated in Step 6. Do not use your regular Google account password.
EnabledToggle to enable or disable the server.
PrimaryEnable to use this server as the primary incoming server.
Outgoing Email ServerEnable to associate an outgoing email server.
Real Time ScanningEnable to scan emails in real time. If disabled, the system scans for new emails every 2 minutes.
Filter TypeSelect Allow to accept only emails from the specified addresses, domains, or keywords (all others are blocked), or Ignore to silently discard emails matching the specified values (all others are allowed). If no filter is configured, ServiceOps accepts emails from all senders by default.
EmailsEnter specific email addresses to filter. With Allow, only these addresses can create tickets. With Ignore, emails from these addresses are silently discarded. Example: hr@company.com. Multiple entries work as OR conditions.
DomainsEnter domain names to filter, without the @ symbol. Example: yahoo.com. With Allow, only emails from these domains create tickets. With Ignore, all emails from these domains are silently discarded. Multiple entries work as OR conditions.
KeywordsEnter words or phrases to match against the email subject and body. With Allow, only emails containing these keywords create tickets. With Ignore, matching emails are silently discarded. Multiple entries work as OR conditions.

Click Save.

Configuring Gmail in ServiceOps (Outgoing)

Navigate to Admin > Support Channel > Emails > Outgoing Email Servers and click Add Outgoing Email Servers.

Enter the following details:

ParameterDescription
NameEnter the name of the email server.
EmailEnter the Gmail address used as the From address for all notifications.
ProtocolSelect SMTP.
Sender NameEnter the display name shown to recipients alongside the From address.
Email ProviderSelect Other.
ServerEnter smtp.gmail.com.
PortEnter the port number. Common values: SMTP (TLS): 587, SMTP (SSL): 465.
Security TypeSelect SSL or TLS.
Authentication NeededEnable to authenticate with the server.
Email Auth TypeSelect Basic Auth.
UsernameEnter the full Gmail address.
PasswordPaste the App Password generated in Step 6. Do not use your regular Google account password.
Reply-To EmailEnter the email address to which recipient replies will be directed. Set this to a monitored mailbox so replies are captured and converted into tickets.
Proxy ServerSelect the required proxy server. Leave blank if ServiceOps has direct internet access.
EnabledToggle to enable or disable the server.
PrimaryEnable to use this server as the fallback when other configured outgoing servers are unavailable.
Filter TypeSelect Allow to send emails only to the specified addresses or domains (all others are blocked), or Ignore to silently block emails to the specified values (all others are allowed). If no filter is configured, ServiceOps sends emails to all recipients by default.
EmailsEnter specific email addresses to filter. With Allow, only these addresses receive emails. With Ignore, emails to these addresses are silently blocked. Example: hr@company.com. Multiple entries work as OR conditions.
DomainsEnter domain names to filter, without the @ symbol. Example: company.com. With Allow, only addresses in these domains receive emails. With Ignore, all addresses in these domains are silently blocked. Multiple entries work as OR conditions.

Click Save. Verify connectivity using the Test Connection button from the list page.

Troubleshooting

Authentication fails with "Invalid credentials" error

Gmail blocks standard account passwords for SMTP and IMAP when 2-Step Verification is enabled. If authentication fails:

  1. Confirm you are using an App Password, not your regular Google account password.
  2. Go to Google Account > Security > App Passwords and generate a new App Password for ServiceOps.
  3. Update the Password field in the ServiceOps email server configuration with the new App Password.
  4. If App Passwords is not visible in your Google Account, 2-Step Verification may not be enabled. Complete Step 3 to 5 above first.
App Passwords option is not visible in Google Account

The App Passwords option only appears after 2-Step Verification is fully enabled. If it is still not visible:

  1. Confirm 2-Step Verification is active at Google Account > Security > 2-Step Verification.
  2. If your account is managed by a Google Workspace admin, the admin may have restricted App Passwords. Contact your Google Workspace admin to enable it.
  3. Some Google Workspace plans disable App Passwords in favour of OAuth. In that case, use Configuring Gmail for OAuth instead.
Emails are not converting into tickets

If the incoming server connects successfully but emails are not creating tickets:

  1. Confirm Email to Ticket is enabled at Admin > Support Channel > Emails > Email Preference.
  2. Confirm IMAP or POP3 is enabled on the Gmail account under Gmail Settings > Forwarding and POP/IMAP.
  3. Check the Filter Type configuration. An Ignore rule may be discarding the sender's emails.
  4. Review the Email Audit log at Admin > Organization > Security > Operation Audit for rejection details.