IDEA keeps asking for GitHub credentials

Answered

Here is my environment:

IntelliJ IDEA 2021.1 (Ultimate Edition)
Build #IU-211.6693.111, built on April 6, 2021
Licensed to *****
Subscription is active until May 9, 2021.
For non-commercial open source development only.
Runtime version: 11.0.10+9-b1341.35 amd64
VM: Dynamic Code Evolution 64-Bit Server VM by JetBrains s.r.o.
Linux 5.8.0-48-generic
GC: G1 Young Generation, G1 Old Generation
Memory: 2048M
Cores: 20
Non-Bundled Plugins: Dart (211.6693.108), io.flutter (55.0.5), io.plugin.tsnode (2020.09.01-0)
Kotlin: 211-1.4.32-release-IJ6693.72
Current Desktop: KDE

and my OS is Ubuntu 20.10.

 

Whenever I try to clone a private repo, use external plugin that interact with Git (ie GitToolbox), or other action that interact with GitHub, the popup asking to login with Git keeps opening (in the settings the GitHub account is already added).

When I clone a private repo even if I log in the clone in the end fails.

I'm aware of https://youtrack.jetbrains.com/issue/IDEA-248658 but seems like that the issue is still happening (I have the issue only in Linux on Windows this is not happening).

 

Anything I could to to fix the issue?

5
24 comments

Hello Mattia

The login prompt can come from GitToolbox plugin. It may ask you to re-login to GitHub since it's doing auto-fetch. You can disable the plugin.

If you are trying to clone a private repository and still prompted to enter credentials it's worth checking whether you have "Use credential helper" enabled under Preferences | Version Control | Git. If it's enabled, please disable it since it will override the account that is used Preferences | Version Control | GitHub and it will use credentials that are stored in credential manager.

4
Avatar
Permanently deleted user

I already had GitToolbox disabled and the credential manager disabled, and still got the prompt.

However after enabling the credential manager it's working fine, without any prompt.

 

Before I had used the command to save the credential so it might be because of that.

git config --global credential.helper store

(I'm aware it's insecure)

0

Thank you for clarification.

If you've managed to login to GitHub in IDE, but your clone is failing - could you please share exact error message that you are having?
Also do you clone from an organization repository by any chance? If so there is a chance that it may have OAuth enable, then please refer to this guide 

0
Avatar
Permanently deleted user

Thanks for the help!

I've managed to login to GitHub in the IDE and clone the repository successfully (before I was recieving an error saying that the repository is not found.)

I'm cloning from an organization repository, however in the way I showed in the previous post fixes the cloning as well.

0

I ran through the same issue while interacting with my remote GitHub Repo through my Ubuntu system. I'm using PyCharm and the solution I found was this:

  1. In your PyCharm, uncheck 'Use credential helper' from File | Settings | Version Control | Git
  2. In your PyCharm, go to File | Settings | Appearance & Behavior | System Settings | Passwords, and select 'In KeePass' option under 'Save passwords' section (by default it is 'In native Keychain' for Ubuntu systems). Source: https://www.jetbrains.com/help/pycharm/using-git-integration.html#set-passwords-for-git-remotes

Note: I do not have the GitToolbox plugin installed in my IDE.

Once completed the above two steps, try interacting with your GitHub remotes, it may ask for credentials for one-time if you haven't already linked your GitHub account. After this, it should not be asking for it again!

Cheers

0

While logging in use `AccessToken`

1

The solution for me was to enable the 'Git credentials helper' in the IntelliJ settings.

16

Filippo Orru thx so much, it worked!

 

6

Thanks Filippo Orru,

'Git credentials helper' works for me too

0

Thanks Filippo Orru, it's worked for me.

0

Still happens to me with 

IntelliJ IDEA 2024.1.4 (Ultimate Edition)
Build #IU-241.18034.62, built on June 20, 2024
Licensed to Armando Ota
Subscription is active until November 10, 2024.
Runtime version: 17.0.11+1-b1207.24 amd64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
Linux 6.5.0-41-generic
GC: G1 Young Generation, G1 Old Generation
Memory: 4096M
Cores: 12
Registry:
 debugger.new.tool.window.layout=true
 ide.experimental.ui=true
Non-Bundled Plugins:
 com.jetbrains.plugins.ini4idea (241.18034.82)
 org.jetbrains.plugins.go-template (241.14494.150)
 com.markskelton.one-dark-theme (5.11.0)
 org.jetbrains.plugins.go (241.17011.2)
 com.jetbrains.space (241.18034.4)
 org.asciidoctor.intellij.asciidoc (0.42.2)
 com.intellij.ml.llm (241.18034.12)
 com.intellij.lang.jsgraphql (241.14494.150)
 com.jetbrains.packagesearch.intellij-plugin (241.0.11)
 com.jetbrains.php (241.18034.69)
Kotlin: 241.18034.62-IJ
Current Desktop: KDE
 

And checked 

version control > git > [X] use credentials helper.

I have to copy paste my password 4 times before it accepts it :D 

 

 

1

they fixed git lfs pushes ? 

0

Thanks Filippo Orru, it's worked for me.

0

For some reason this started happening to me just with the recent update (IntelliJ IDEA 2025.2.2 (Ultimate Edition), Build #IU-252.26199.169, built on September 18, 2025, on Mac) but Filippo Orru's solution worked for me. Thanks!

0

I have been forced by my company to switch from Ultimate to community edition :(

But in both flavors, I have found that I am continuously prompted for my GitHub Authorization. as in 5 - 10 tiumes a DAY.

I consider this a BUG.

I have tried both the the Use Token… and Log in via GitHub… buttons and for what ever reason it is failing to store my credentials. Even when I get this prompt in IntelliJ, I can instantly switch from IDE to CLI and push, pull, etc. without fail. So my connection is stable but IntelliJ is forgetting my credentials over and over again!

0

Tully, Christopher 

Could you please share screenshots of the following settings pages:

  • Settings (⌘ + , or Ctrl + Alt + S) > Appearance & Behavior > System Settings > Passwords
  • Settings (⌘ + , or Ctrl + Alt + S) > Version Control > Git

You can upload the files to our secure FTP server: https://uploads.jetbrains.com, just provide the uploaded file ID.

0

Ivan Pajic my company blocks FTP and SFTP for security reasons…

 


 

0

I do also have GitToolbox installed.

0

Tully, Christopher 
Thank you for the update.

I see that the credentials are stored In KeePass, which is the recommended option. But there could be some problem with accessing it on your machine. Could you try with the first option - In native Keychain?

I do also have GitToolbox installed.

As a test, could you try to disable all downloaded/non-bundled plugins? Just to check if it will affect the behavior. You can easily re-enable them the same way.

Even when I get this prompt in IntelliJ, I can instantly switch from IDE to CLI and push, pull, etc. without fail. 

Do you get the mentioned error messages when performing remote git operations as well, like pull/push/fetch etc.?
Could you please share a screenshot of the error message that is shown during such operation from the IDE - for example push?

 

0

I almost never use GUI tools for git operations. I do all push/pull/status commands on the CLI.

I am not seeing errors in the GUI. Just repeated prompts to enter my GitHub PAT again or login via GitHub again.

Which is more likely a fix? A - Switch to KeePass or B - The non-bundled plugin?

0

Thanks for the update.

Which is more likely a fix? A - Switch to KeePass or B - The non-bundled plugin?

Credentials for the GitHub plugin - the one which displays the errors - are stored in KeePass. So it could help to use the In native Keychain option. On the other hand, if you have some custom plugins installed which could affect this behavior, it could also be the root cause. So for now not sure. 

It would help to have a look at the IDE logs (Help > Collect Logs and Diagnostic Data). Could you please restart IDE, reproduce the issue again and share your logs? You can upload them to our secure server: https://uploads.jetbrains.com. The upload goes via https, so I think you should be able to upload.

0

For the moment I have switched from the “In KeePass” as shown in my screenshot to “In native keychain”. If the issues continue, then I will enable logging and upload them. 

1

Well nearly 2 full work days and no login prompts. I will update again sometime next week.

1

Please sign in to leave a comment.