Pycharm GitHub 'Push failed: fatal: Authentication failed'

Every time I try to push a repository in GitHub with Pycharm the it fails.

Push failed: fatal: Authentication failed for ' github repository)/'

In Settings->Version Control->GitHub, I filled the fields Host, Loging and Password (Auth Type: Password). Testing it: “Connection successful”

In Settings->Version Control->Git, Path to Git executable is seted with the full path, SSH executable: Buil-in

Pycharm version 3.1.1
Git version 1.8.4.msysgit.0
On Win 7.

  • how to change gitconfig location?
  • Running “git status” against a repository located elsewhere in the system
  • Automated GIT clone
  • git diff and git difftool do nothing and give no output
  • Git on Windows: Force use of OpenSSH
  • Git on a Windows Lan
  • restore windows command prompt tools after git bash replace them with unix tools
  • Git uses invalid author name in commits
  • 3 Solutions collect form web for “Pycharm GitHub 'Push failed: fatal: Authentication failed'”

    It seems there is some issue (if using https) if username or password contains “some” special characters.

    So, I’ve generated a secondary password (“personal access token”) in GitHub’s application settings page (using the “Create new token” button), I did copy this token. Then I’ve selected Auth Type: Token in Settings->Version Control->GitHub, and pasted the token.

    Testing it: Connection successful for user . Now the git push works perfectly.

    If your username or password has special characters, you can replace it with the Percent-encoding for theses characters.
    for example, if your password is “test@2010”, you will write it as “test%402010” and the config command will be like this
    git config remote.origin.url https://{username}{repo_username}/{repo_name}.git

    So I found the solution to my problem, and I hope this helps:

    If you are using KDE, or Gnome, your “KDE Wallet”, or “Gnome Keyring” manager will save your password when you push for the first time. However, if you enter the password wrong, these managers (ksshaskpass for KDE) will store the wrong password and will send the wrong password every time.

    To fix this, open the appropriate manager and change the password. With KDE, it is in: Kick-off-menu > System Settings > Account Details > KDE Wallet, then click “Launch Wallet Manager”, and find “ksshaskpass”, expand it, and then expand “Passwords”, then find your github registered email address there, click it, and on the right, click on “Show Contents”. Now change that value (in case wrong password), then hit save. and you’re done!

    Now that means you don’t have to type in your password each time for https push, and you don’t have to use SSH keys either 😉

    Git Baby is a git and github fan, let's start git clone.