Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Learn More
Open

Hotmail account: OAuth2 sign-in succeeds but IMAP/POP always fails with "Authentication error" (Thunderbird 160)

Pedro Martins

I can't add my personal @hotmail.com account to Thunderbird. Every attempt ends with "Authentication error – Unable to log in at server. Probably wrong configuration, username or password." All my other accounts (Gmail and several Microsoft 365 business accounts using outlook.office365.com + OAuth2) work fine in the same profile.

Setup

What happens

  • The Microsoft sign-in opens in my default browser, I sign in with the correct account (2FA), and I get the "You're all set" page.
  • With mailnews.oauth.loglevel = All, the Error Console shows a successful token response from login.microsoftonline.com with scopes IMAP.AccessAsUser.All, POP.AccessAsUser.All and SMTP.Send, and "Creating new login for ...@hotmail.com". Microsoft also emails me "New app(s) connected to your account".
  • Immediately after that, account setup fails with "Unable to log in at server". The console shows nothing more specific.

What I already tried

  • Removed and re-added the account several times; cleared the saved OAuth logins for this address
  • Cookies are allowed; mailnews.oauth.useExternalBrowser is back to true (setting it to false made the redirect go to https://127.0.0.1 and fail)
  • In Outlook.com: IMAP is enabled (toggled off/on and saved). The address is the primary alias of the Microsoft account. Two-step verification is on. Recent activity shows no blocked or unusual sign-ins, even right after a failed attempt.
  • Webmail works normally.
  • Microsoft support says nothing is blocked on their side and sent me here.

Is there anything else I can check, or a way to see the actual IMAP server response to find out why it rejects the token?

I can't add my personal @hotmail.com account to Thunderbird. Every attempt ends with "Authentication error – Unable to log in at server. Probably wrong configuration, username or password." All my other accounts (Gmail and several Microsoft 365 business accounts using outlook.office365.com + OAuth2) work fine in the same profile. '''Setup''' * Thunderbird 160.0 (64-bit) on Windows (problem also happened on 159.0) * Settings auto-detected by the Account Hub: IMAP outlook.office365.com:993 SSL/TLS OAuth2; SMTP smtp-mail.outlook.com:587 STARTTLS OAuth2 * POP3 (outlook.office365.com:995 SSL/TLS OAuth2) fails in exactly the same way '''What happens''' * The Microsoft sign-in opens in my default browser, I sign in with the correct account (2FA), and I get the "You're all set" page. * With mailnews.oauth.loglevel = All, the Error Console shows a successful token response from login.microsoftonline.com with scopes IMAP.AccessAsUser.All, POP.AccessAsUser.All and SMTP.Send, and "Creating new login for ...@hotmail.com". Microsoft also emails me "New app(s) connected to your account". * Immediately after that, account setup fails with "Unable to log in at server". The console shows nothing more specific. '''What I already tried''' * Removed and re-added the account several times; cleared the saved OAuth logins for this address * Cookies are allowed; mailnews.oauth.useExternalBrowser is back to true (setting it to false made the redirect go to https://127.0.0.1 and fail) * In Outlook.com: IMAP is enabled (toggled off/on and saved). The address is the primary alias of the Microsoft account. Two-step verification is on. Recent activity shows no blocked or unusual sign-ins, even right after a failed attempt. * Webmail works normally. * Microsoft support says nothing is blocked on their side and sent me here. Is there anything else I can check, or a way to see the actual IMAP server response to find out why it rejects the token?

You must log in to your account to reply to posts. Please start a new question, if you do not have an account yet.