Could not pull from git repository – wrong credentials on windows

I changed my password on the github repository and Intellij asks again for the new credentials. I used the new credentials but it still tells me that I am using wrong credentials. I tried using the old credentials and it still gives me the wrong credentials. I invalidating cache and restarting IntelliJ, but it didn't work and I also tried from windows terminal but it still returns invalid credentials. I tried logging in via the webpage and it works


Linux offers much more pleasant working environment than windows. Try using it instead.
Djordje Bulatovic - Fri, 12/11/2020 - 14:32 :::
1 answer

This problem is caused by windows saving credentials, like a password manager. Once you login to github via Intellij these credentials are saved in windows and everytime you connect to your github account it will use the saved credentials instead of the written ones. To remove the credentials in windows go to Control Panel, then click on User Accounts. In this window click on Credential Manager, the git credentials should be under Windows Credentials. Find the credentials that you need, click on them and then click on remove.