kmail/akonadi can't connect to gmail account

If I try to add a Gmail account to kmail, it is rejected every time with the following message (in a new window)

Sign in with Google temporarily disabled for this app

This app has not been verified yet by Google in order to use Google Sign In.
I saw the login method is gmail but it was greyed out so I wanted to add i manual so I can select PLAIN auth method. kmail detects it is a gmail adress and doesn’t let me change the auth method.

Another private IMAP-mail works perfect. Also I can connect to my google calenders and contacts. Only mail doesn’t work

You need to go on the online google account manager.
After you login online, you will be able to authorize kmail to login and to generate a key that will replace your password.

Do you mean App passwords in the “Signing in to google” cards under Security.
I did that already but it doesn’t change anything

I mean this :

it will lead you to make a special password for kmail .
That’s what i did and i can pull the mails from gmail with kmail, using pop ;o)

And, something which I find to be quite annoying with Google and Microsoft accounts accessed from Linux machines is, e-Mails from the accounting system containing (sorry for the German language):

Neues Gerät angemeldet

Jemand hat sich über ein neues Linux-Gerät in Ihrem Google-Konto angemeldet. Sie haben diese E-Mail erhalten, weil wir uns vergewissern möchten, dass es sich hierbei um Sie handelt.

And, when I login to the account, with IPv4 addresses, Goggle and Co. assume that I’m in Munich, which I’m not and, with the newest e-Mail, they’re assuming that, my IPv6 address is “somewhere in Germany”, which I am …

I suppose that, this is comforting for most people – at least they’ve noticed that, it’s neither the Mobile Android Telephone nor a Windows machine which accessed the account …

I got it working but it’s pretty slow.
If you modify the account settings and for the IMAP server you put instead of, you are able to connect. But the annoying message that kmail is temporary suspended is still there

These imap servers are aliases for eachother, doesn’t really matter. You should check Google’s SSL/TLS settings and adjust the account’s settings accordingly. Another thing to consider is the fact that akonadi is indexing the emails in the account. Depending on the no of emails, folders etc, this can cause initial slowness ( database is building ).