
Quick answer: IMAP not working is most often caused by incorrect server settings, IMAP being disabled in the provider's account settings, an app-specific password being required (Gmail with 2FA), or a firewall blocking the IMAP port (993). Verifying server settings against the provider's current documentation and confirming IMAP is enabled in the account settings resolves the majority of IMAP connection failures.
"My Email Client Stopped Connecting" — What IMAP Errors Actually Mean
A situation that comes up regularly when setting up or maintaining a third-party email client: the client reports that it cannot connect to the mail server, or that authentication has failed, or that the connection timed out. The error messages from email clients are often cryptic — "Cannot connect to server," "Authentication failed," "Connection refused on port 993" — and do not clearly indicate whether the problem is with the server settings, the account credentials, the network, or the email client itself. IMAP errors are among the more technically involved email troubleshooting problems, but they follow a consistent pattern that makes them diagnosable with the right approach. This guide covers the most common causes of IMAP not working in email clients including Apple Mail, Thunderbird, Outlook (as a client for non-Microsoft accounts), and other IMAP-compatible clients — for Gmail, Outlook.com, and other major providers. IMAP server settings and authentication requirements change over time; verifying current settings against the provider's documentation before configuring a new account is always recommended.

How IMAP Works — and Where It Breaks
IMAP (Internet Message Access Protocol) is the protocol that email clients use to connect to a mail server and access messages stored there. Unlike POP3, which downloads messages to the local device and typically removes them from the server, IMAP keeps messages on the server and synchronizes the local client with the server state — changes made in one client (reading, deleting, moving messages) are reflected in all other clients connected to the same account. IMAP connections use port 993 with SSL/TLS encryption, or port 143 with STARTTLS — port 993 with SSL/TLS is the current standard and is required by most providers. An IMAP connection requires four things to work correctly: the correct server hostname and port, the correct authentication credentials (username and password, or an app-specific password), SSL/TLS configured correctly, and a network path that allows the connection (no firewall or security software blocking the port). If any of these four elements is incorrect or blocked, the connection fails. The error message from the email client usually indicates which element is the problem — a "connection refused" or "timeout" error suggests a network or port issue; an "authentication failed" error suggests a credentials issue; a "certificate error" suggests an SSL/TLS configuration issue. Provider-side requirements have become more complex in recent years. Google requires app-specific passwords for IMAP access when two-factor authentication is enabled. Microsoft has been moving Microsoft 365 accounts toward modern authentication (OAuth), which some older email clients do not support. Yahoo requires app passwords for IMAP access. These requirements change over time — checking the provider's current IMAP documentation before configuring a new account avoids the most common setup errors.
IMAP Not Working — 5 Common Causes and Fixes
Error / SymptomLikely CauseFixCannot connect to serverWrong hostname or portVerify settings against provider docsAuthentication failedWrong password or app password neededGenerate app password; re-enter credentialsConnection refused / timeoutFirewall or antivirus blocking port 993Allow port 993 in firewall / disable AV scanIMAP disabled errorIMAP not enabled in account settingsEnable IMAP in provider's web settingsSSL/TLS certificate errorWrong SSL setting or outdated clientSet SSL/TLS on port 993; update client
1. Incorrect Server Settings
The most common cause of IMAP connection failure when setting up a new account is incorrect server settings — wrong hostname, wrong port, or wrong SSL/TLS configuration. Email clients sometimes auto-configure settings based on the email address domain, but auto-configuration is not always accurate, and provider settings change over time. The correct settings for the most common providers are: Gmail — imap.gmail.com, port 993, SSL/TLS; Outlook.com — outlook.office365.com, port 993, SSL/TLS; Yahoo Mail — imap.mail.yahoo.com, port 993, SSL/TLS; Apple iCloud — imap.mail.me.com, port 993, SSL/TLS. For SMTP (outgoing mail), the settings are: Gmail — smtp.gmail.com, port 465 (SSL) or 587 (TLS/STARTTLS); Outlook.com — smtp.office365.com, port 587, STARTTLS; Yahoo Mail — smtp.mail.yahoo.com, port 465 (SSL) or 587 (STARTTLS). These settings should be verified against the provider's current support documentation before configuring, as they may change. Using port 993 with SSL/TLS (not STARTTLS) for IMAP and port 587 with STARTTLS for SMTP is the current standard for most providers.
2. App-Specific Password Required
Gmail, Yahoo Mail, and some other providers require an app-specific password for IMAP access when two-factor authentication (2FA) is enabled on the account. An app-specific password is a 16-character code generated in the account's security settings that is used in place of the regular account password in the email client. The regular account password will not work for IMAP when 2FA is enabled — entering it results in an "authentication failed" error even though the password is correct. For Gmail, app passwords are generated at myaccount.google.com/apppasswords — the account must have 2FA enabled to access this page. Select "Mail" as the app and the device type, then click Generate. Copy the 16-character code and enter it as the password in the email client's account settings. For Yahoo Mail, app passwords are generated at login.yahoo.com/account/security under "Generate app password." Each email client should have its own app password — if the same app password is used in multiple clients and one client is removed, revoking that app password does not affect the others.
3. IMAP Disabled in Account Settings
Some email providers disable IMAP access by default and require it to be explicitly enabled in the account settings. Gmail is the most common example: IMAP must be enabled in Gmail's web settings before any email client can connect via IMAP. To enable IMAP in Gmail, log into Gmail in a browser, go to Settings (gear icon) > See all settings > Forwarding and POP/IMAP tab > IMAP Access section, and select "Enable IMAP." Click Save Changes. After enabling IMAP, the email client should be able to connect — if it was already configured with the correct settings, it may connect automatically after IMAP is enabled. For Microsoft 365 business accounts, IMAP access may be disabled by the organization's administrator as a security policy. In this case, the IT administrator needs to enable IMAP for the affected mailbox in the Microsoft 365 admin center or Exchange admin center. Individual users cannot enable IMAP themselves if it has been disabled at the organizational level. Checking with the IT administrator before spending time troubleshooting other causes is recommended for Microsoft 365 business accounts.
4. Firewall or Antivirus Blocking the IMAP Port
A firewall or antivirus program on the device can block the IMAP port (993), preventing the email client from connecting to the mail server. This is a common cause of IMAP connection failures that appear as "connection refused" or "connection timed out" errors — the email client is attempting to connect to the correct server on the correct port, but the connection is being blocked before it reaches the server. The diagnostic test is to temporarily disable the firewall or antivirus and attempt the IMAP connection — if it succeeds, the security software is the cause. The fix is to add an exception for the email client or for port 993 in the firewall or antivirus settings, rather than leaving the security software disabled. The specific steps for adding an exception vary by firewall and antivirus product — checking the product's documentation for "allow application" or "port exception" instructions is the most reliable approach. On Windows, the built-in Windows Defender Firewall can be configured through Control Panel > System and Security > Windows Defender Firewall > Allow an app or feature through Windows Defender Firewall.

5. SSL/TLS Configuration Error or Outdated Email Client
⚠️ Worth checking if other fixes have not worked: SSL/TLS configuration errors produce certificate warnings or connection failures that can be confused with other types of IMAP errors. The most common SSL/TLS issues are: the email client is configured to use STARTTLS on port 993 instead of SSL/TLS (port 993 requires SSL/TLS, not STARTTLS — STARTTLS is used on port 143 or 587), the email client's SSL certificate store is outdated and does not trust the server's certificate, or the email client version is too old to support the server's current TLS version. Ensuring the email client is updated to the latest version and that the SSL/TLS setting in the account configuration matches the provider's requirements (SSL/TLS on port 993) resolves most SSL-related IMAP failures. If a certificate warning appears, do not accept an untrusted certificate — instead, investigate why the certificate is not being trusted before proceeding.
Step-by-Step: How to Fix IMAP Not Working
Step 1: Verify Server Settings Against Provider Documentation
Before changing anything else, verify the IMAP server settings in the email client against the provider's current documentation. Search for "[provider name] IMAP settings" to find the official support page — for Gmail, this is support.google.com/mail/answer/7126229; for Outlook.com, this is support.microsoft.com/en-us/office/pop-imap-and-smtp-settings. Compare the hostname, port, and SSL/TLS setting in the email client to the values in the documentation. Correct any discrepancies and test the connection. Incorrect server settings are the most common cause of IMAP failures when setting up a new account.
Step 2: Enable IMAP in the Provider's Web Settings
Log into the email account in a web browser and check whether IMAP is enabled. For Gmail: Settings > See all settings > Forwarding and POP/IMAP > IMAP Access > Enable IMAP > Save Changes. For Yahoo Mail: Account Security settings > Allow apps that use less secure sign-in (or generate an app password). For Microsoft 365 business accounts: contact the IT administrator to confirm IMAP is enabled for the mailbox. After enabling IMAP, return to the email client and test the connection.
Step 3: Generate and Use an App-Specific Password
If the account has two-factor authentication enabled (Gmail, Yahoo, or other providers that require app passwords), generate an app-specific password and use it in the email client instead of the regular account password. For Gmail: myaccount.google.com/apppasswords > Select app: Mail > Select device > Generate. For Yahoo: login.yahoo.com/account/security > Generate app password. Enter the generated 16-character code as the password in the email client's account settings. If the email client was previously configured with the regular password, update the password field with the app password and test the connection.
Step 4: Check Firewall and Antivirus Settings
Temporarily disable the firewall and antivirus on the device and test the IMAP connection. If the connection succeeds with the security software disabled, add an exception for the email client or for port 993 in the firewall and antivirus settings, then re-enable the security software. If the connection still fails with the security software disabled, the firewall is not the cause — re-enable the security software and proceed to the next step.
Step 5: Update the Email Client and Check SSL/TLS Configuration
Update the email client to the latest version — outdated clients may not support the server's current TLS version or authentication requirements. After updating, verify that the SSL/TLS setting in the account configuration is set to "SSL/TLS" (not "STARTTLS" or "None") for the IMAP port 993. In Apple Mail, this setting is in Mail > Preferences > Accounts > [Account] > Account Information > Incoming Mail Server > Advanced. In Thunderbird, it is in Account Settings > Server Settings > Connection Security. In Outlook (as an IMAP client), it is in File > Account Settings > Account Settings > [Account] > Change > More Settings > Advanced. After updating the SSL/TLS setting, test the connection.
Frequently Asked Questions — IMAP Not Working
Why is IMAP not working?
The most common causes are incorrect server settings, IMAP being disabled in the provider's account settings, an app-specific password being required (Gmail and Yahoo with 2FA enabled), a firewall blocking port 993, or an SSL/TLS configuration mismatch. Verifying server settings against the provider's current documentation is the most reliable first step.
What are the correct IMAP settings for Gmail?
Gmail IMAP: server imap.gmail.com, port 993, SSL/TLS. Gmail SMTP: server smtp.gmail.com, port 465 (SSL) or 587 (STARTTLS). IMAP must be enabled in Gmail settings. If 2FA is enabled, an app password from myaccount.google.com/apppasswords is required. Verify against Google's current support documentation before configuring.
What are the correct IMAP settings for Outlook?
Outlook.com IMAP: server outlook.office365.com, port 993, SSL/TLS. Outlook.com SMTP: server smtp.office365.com, port 587, STARTTLS. For Microsoft 365 business accounts, settings may differ — check with the IT administrator or Microsoft's current documentation.
Does Gmail require an app password for IMAP?
Yes, if two-factor authentication is enabled on the Google account. Generate an app password at myaccount.google.com/apppasswords and use the 16-character code as the password in the email client instead of the regular account password. If 2FA is not enabled, the regular password can be used, though Google's requirements for less secure app access have been changing.
Why does IMAP work on one device but not another?
Device-specific IMAP failures typically indicate a firewall or security software blocking port 993 on the non-working device, an outdated email client version, incorrect account settings on the non-working device, or a VPN or proxy interfering with the connection. Comparing account settings between the working and non-working devices is the fastest diagnostic step.
Conclusion & My Take
IMAP not working is almost always caused by one of five things: incorrect server settings, IMAP disabled in the account, an app password requirement, a firewall blocking port 993, or an SSL/TLS configuration mismatch. Working through these in order — starting with server settings verification and IMAP enablement, then credentials, then network issues — resolves the majority of IMAP connection failures without requiring advanced troubleshooting. The app password requirement is worth highlighting because it is the most common source of confusion for users who have 2FA enabled on Gmail or Yahoo accounts. The regular account password is correct — it works for web login — but it does not work for IMAP when 2FA is active. Generating an app password and using it in the email client is a one-time setup step that resolves this category of failure immediately. Keeping a record of which app passwords have been generated for which clients makes it easier to revoke specific app passwords if a device is lost or a client is removed. Have you encountered an IMAP error that was not resolved by these steps, or found a provider-specific configuration requirement that was not well documented? IMAP configuration requirements vary by provider and change over time — feel free to share your experience in the comments below.
Sources
Google — Check Gmail Through Other Email Platforms (IMAP Settings) — support.google.com
Microsoft — POP, IMAP, and SMTP Settings for Outlook.com — support.microsoft.com
Yahoo — Yahoo Mail IMAP Settings — help.yahoo.com
IETF RFC 9051 — Internet Message Access Protocol (IMAP) Version 4rev2 — datatracker.ietf.org
IETF RFC 8314 — Cleartext Considered Obsolete: Use of TLS for Email — datatracker.ietf.org









