Unable to add Gmail account to Apple Mail or System Preferences - deleting from keychain worked for me
Hi, I had an issue with adding a gmail account to System Preferences (or Mail.app). On Catalina, System Prefs would handoff to Safari, and I would authenticate with my gmail account, but eventually I would get kicked back to System Preferences with a message that my google account could not be authenticated, please try again later. (or something like that)
A few notes
- I could add this gmail account to System preferences under a different macOS User account.
- I could add different gmail accounts to this macOS user's account.
I tried a few things based on others' suggestions around here.
- remove malware (found some)
- disable socks proxy (wasn't set)
What fixed it for me was to open Keychain Access and remove any items related to google.com or gmail login. I think these were the important ones:
- com.apple.account.Google.oauth-token
- com.apple.account.Google.oauth-expiry-date
- There was another like that I deleted.
After removing those from the keychain, I was able to add the account to System Preferences. I hope this helps.