Blog/ Gmail how-tos

How to Use Gmail as an Email Client in Another App

Nafiul HasanNafiul Hasan· 11 min read
Illustration of a third-party email client connecting to Gmail over IMAP, with Gmail labels mapped to parallel IMAP folder views and the OAuth sign-in flow highlighted

The short answer

To use Gmail in another email app, add your Gmail address and choose Sign in with Google (OAuth). If the app only offers a password field, use a 16-character app password with imap.gmail.com port 993 and smtp.gmail.com port 465 or 587. Your normal Gmail password is rejected, for personal and Workspace accounts alike.

Use Gmail in Apple Mail, Outlook or another email app: sign in with Google (OAuth), IMAP/SMTP settings, and how to fix duplicates and delete-vs-archive.

On this page
  1. 01The short answer: three steps
  2. 02Gmail IMAP and SMTP settings for another email app
  3. 03Which kind of client are you using?
  4. 04What you need before you start
  5. 05How to connect Gmail to a third-party email client
  6. 06How Gmail behaves differently over IMAP
  7. 07What to do when it does not work
  8. 08Does Gmail IMAP have daily limits?
  9. 09Scope note: adding other accounts to Gmail
  10. 10A client that connects through the Gmail API

To use Gmail as an email client in another app, such as Apple Mail, Outlook or Thunderbird, you add your Gmail address inside that app and choose Sign in with Google. The app gets a revocable token instead of your password, which is the method Google recommends. Only if the app offers nothing but a password field do you need an app password plus the IMAP and SMTP settings below.

The rest of this guide covers the settings, what Google changed about passwords, why Gmail's labels cause duplicates and archive-on-delete over IMAP, and how to fix each symptom. This page is about reading Gmail inside another app. If you want the reverse, pulling other accounts into Gmail, see the scope note near the end: Google is retiring several of those features in January 2027.

The short answer: three steps#

Connecting takes three steps. The detail behind each one follows in the sections below.

  1. 1

    Sign in with Google in the app

    Add a new account in the client, choose Google or Gmail, and approve access in the browser window Google opens. Your Gmail password is never typed into the client.

  2. 2

    If it only offers a password field, use an app password

    Turn on 2-Step Verification, generate a 16-character app password in your Google Account, and paste it as the password with your full Gmail address as the username. Google says app passwords are unnecessary in most cases, so try Sign in with Google first.

  3. 3

    Set delete behavior and which labels show up

    IMAP clients see every Gmail label as a folder. Decide what delete should do and hide the labels you do not want listed, so you avoid duplicates and surprise archiving.

Gmail IMAP and SMTP settings for another email app#

Clients that sign in with Google usually fill these in for you. Use them when you set the account up by hand. Google's own Workspace help lists the same hosts and ports.

SettingValue
Incoming server (IMAP)imap.gmail.com
Incoming port and security993, SSL/TLS
Outgoing server (SMTP)smtp.gmail.com
Outgoing port and security465 with SSL/TLS, or 587 with STARTTLS
UsernameYour full Gmail or Workspace address
PasswordNot your Gmail password. Either the OAuth token the client gets after Sign in with Google, or a 16-character app password

Which kind of client are you using?#

Not every app that shows your Gmail talks to Google the same way, and that decides which problems you will hit. An IMAP client reads Gmail as if it were an ordinary mail server, so the label-versus-folder quirks in this guide apply to it. A client built on the Gmail API reads labels as labels, so there is no folder mapping to tune and no archive-versus-delete setting to change.

Many apps that offer Sign in with Google still use IMAP underneath, because OAuth is only the sign-in step. If you are choosing between the two styles, Gmail API vs IMAP explains how to tell which one an app uses and what changes day to day.

What you need before you start#

Check these three things first. They account for most failed first connections.

  • IMAP access: on personal Gmail, Google says IMAP is always on and removed the Enable and Disable options in January 2025, so the toggle you may see in older guides is gone. On Google Workspace, your administrator must allow IMAP in the Admin console before an IMAP client can sync. If the Forwarding and POP/IMAP tab is missing for you, an organization policy is the likely reason.
  • A supported sign-in method: Sign in with Google (OAuth), or an app password. Current versions of Outlook, Apple Mail and Samsung Mail support OAuth, according to Google's Workspace help.
  • For an app password: 2-Step Verification must be on for the Google Account before the option appears.

Password-only sign-in is gone for Gmail and Workspace

Google no longer supports third-party apps that sign in with only your username and password. For personal accounts that happened in 2022. For Google Workspace accounts the cutoff was 1 May 2025, and clients must use OAuth. A client that offers neither Sign in with Google nor an app password field cannot connect.

How to connect Gmail to a third-party email client#

  1. 1

    Confirm IMAP access

    Personal Gmail: nothing to switch on, since Google says IMAP access is always on. Workspace: ask your administrator to turn on IMAP in the Admin console if your client reports that IMAP is disabled. This applies to IMAP-based clients. Apps that use the Gmail API do not depend on the IMAP setting.

  2. 2

    Add the account and choose Sign in with Google

    In the client, choose Add Account, then Google or Gmail, enter your address and approve access in the browser prompt. If you used the account in this client before and it fails, remove it and add it again, then look for the Sign in with Google option. Google's help suggests this when sign-in errors persist.

  3. 3

    Or use an app password

    If the client only asks for a server and password, open your Google Account security settings, create an app password for it and copy the 16-character code when it appears. Enter your full Gmail address as the username and the code as the password. Do not enter your regular Gmail password, because it will be rejected.

  4. 4

    Enter the server details if the client asks

    Incoming IMAP: imap.gmail.com, port 993, SSL/TLS. Outgoing SMTP: smtp.gmail.com, port 465 (SSL/TLS) or 587 (STARTTLS), with authentication on. Clients that finished the Google sign-in usually fill these in themselves.

  5. 5

    Review the folder list and set delete behavior

    Gmail shows one IMAP folder per label plus the [Gmail] system folders such as All Mail, Sent Mail, Drafts, Spam and Trash, so expect a longer list than on other providers. In Gmail's web settings, under Forwarding and POP/IMAP, look for the option that controls what happens when a client deletes a message: archive it, move it to Trash, or delete it immediately. Labels and layout can differ by version, so follow the current wording in Gmail.

How Gmail behaves differently over IMAP#

Gmail was built around labels, not folders. IMAP was built around folders. Gmail bridges the two by showing every label as an IMAP folder, and that translation causes most of the complaints. These four behaviors cover almost all of them. For depth, see Gmail IMAP duplicate emails and Gmail IMAP delete vs archive.

BehaviorStandard IMAPGmail over IMAPFix
Message storage and duplicatesA message lives in one folderEvery message lives in [Gmail]/All Mail, and each label shows the same message again as its own folder. A message with three labels appears in three placesHide All Mail from IMAP and sync only Inbox, Sent and the labels you use
Delete behaviorClient marks the message deleted and expunges itBy default removes the Inbox label only, so the message is archived in All Mail rather than deletedChange the delete option under Forwarding and POP/IMAP in Gmail settings
Special folder namesTrash, Drafts and Sent are standard namesGmail uses [Gmail]/Trash, [Gmail]/Drafts and [Gmail]/Sent Mail, which some clients do not map by themselvesMap the client's special folders to the [Gmail] equivalents in account settings
Label hierarchyNested folders are independent containersA label named Work/Project shows as a folder named Project nested under WorkNo action needed, the difference is cosmetic in most clients

The root cause is one architectural fact: every message is stored once, and labels are extra views on top of it. A client that syncs every folder downloads the same message once per label. So the fix is nearly always the same: tell the client which folders to sync and which to ignore. If Outlook is your client, the steps are in how to add a Gmail account to Outlook.

Illustration of one envelope reaching a junction and routing along a solid main path to one box while dotted paths branch to two other boxes, a loose picture of one message appearing in several places
One message, several folder views: Gmail keeps a single copy and shows it under every label.

What to do when it does not work#

Most Gmail-plus-IMAP problems fall into a handful of patterns. Find your symptom below.

SymptomLikely causeFix
Authentication failed or invalid credentialsPassword-only sign-in is not supported, or an app password was revokedRemove the account, add it again and choose Sign in with Google, or generate a new app password
Same email appears multiple timesClient is syncing both All Mail and the label foldersIn Gmail web settings, open the Labels tab and clear Show in IMAP for All Mail, then resync
Delete archives instead of removing the messageGmail's default IMAP delete removes the Inbox label onlyChange the IMAP delete option in Gmail settings to move to Trash
Hundreds of folders in the clientEvery Gmail label becomes an IMAP folderClear Show in IMAP for labels you do not need in the client
Client connects but cannot sendSMTP authentication is off or the wrong port is setUse smtp.gmail.com on 465 (SSL/TLS) or 587 (STARTTLS), with the same OAuth sign-in or app password
Sent mail appears twiceThe client saves a sent copy and Gmail saves one tooTurn off the client's save-sent-copies-to-server setting, or map its Sent folder to [Gmail]/Sent Mail
Sync stops with a bandwidth errorDaily IMAP download or upload limit reachedWait for the limit to reset and sync fewer folders. See the limits section below

Check access before debugging credentials

If a client that used to work stops syncing, first check whether IMAP is still allowed for your account. On Workspace, an admin policy change is the usual cause. Then check whether the client is still using an old password-based sign-in.

Does Gmail IMAP have daily limits?#

Yes. Google lists IMAP bandwidth limits of 2,500 MB of downloads and 500 MB of uploads per day, and says they may change without notice. A first sync of a large mailbox, or a tool that rescans many folders, can reach the download limit. Details and recovery steps are in Gmail IMAP bandwidth limits.

Sending has its own limits. For personal accounts, Google's help lists a ceiling of 500 recipients in one email and 500 emails in one day, and Workspace limits are set out on a separate Google page.

Scope note: adding other accounts to Gmail#

This page is about opening Gmail in another app. If you want the reverse, getting Yahoo, Outlook or other mail into Gmail itself, note that Google says it is ending POP fetching (Check mail from other accounts), Gmailify and Send mail as for third-party addresses in January 2027. The alternative Google suggests is a desktop mail client that connects to those accounts over IMAP and SMTP, or each provider's own app.

A client that connects through the Gmail API#

Everything above exists because IMAP treats labels as folders. AI Emaily connects Gmail with Google sign-in (OAuth) and the Gmail API, so there is no IMAP folder mapping to tune, no per-label duplicate copies and no archive-versus-delete setting to manage. On Google Workspace, your administrator needs to allow third-party app access, which most already do. AI Emaily also offers an IMAP app-password path as a fallback, and the IMAP notes in this guide apply if you choose it.

Beyond the connection, AI Emaily triages incoming mail into a short list of what needs you and drafts replies from the Personal Context you set and per-client profiles. Manual, Copilot and Autopilot modes let you choose how much the agent does, with undo and an audit trail. There is a 7-day free trial on Pro or Autopilot, and you can compare plans on the pricing page.

Frequently asked

Nafiul Hasan

Written by

Nafiul Hasan

Nafiul Hasan is an entrepreneur and AI automation system builder with 10+ years of experience turning messy, manual workflows into reliable automated systems. He designs and ships AI enterprise solutions end-to-end — the agent logic, the data plumbing, and the product people actually use — and founded AI Emaily to give busy professionals their attention back. He writes here from the builder's seat: what works, what breaks, and how to put AI to work without giving up control.

EntrepreneurAI Automation System BuilderAI EnthusiastBuilds AI Enterprise Solutions10+ years experience
More from Nafiul
Ready when you are

Skip the IMAP quirks with a Gmail API client

AI Emaily connects Gmail through Google sign-in and the Gmail API, triages your inbox, and drafts replies from the Personal Context you set. 7-day free trial on Pro or Autopilot.

  • 7-day free trial
  • Cancel anytime
  • Every provider