6

After I issued

git push origin <branch-name>

and entered the access credentials, Git returned an error like so

remote: Repository not found.
fatal: Authentication failed for 'https://github.com/<account-name>/<repository-name>.git'

What seems to be the problem?

michas
  • 25,361
  • 15
  • 76
  • 121
Abel Callejo
  • 13,779
  • 10
  • 69
  • 84
  • 1
    possible duplicate of [Cloned directly from repo...get error when pushing](http://stackoverflow.com/questions/19777122/cloned-directly-from-repo-get-error-when-pushing) – Monika Nov 14 '13 at 06:30
  • possible duplicate of [GitHub Error: Repository Not Found](http://stackoverflow.com/questions/10184433/github-error-repository-not-found) – random Nov 15 '13 at 04:11

1 Answers1

16

The GitHub help page, "Error: Repository not found" summarizes the possible causes:

Community
  • 1
  • 1
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
  • 1
    Tracking URLs don't count as referrals when linked to from a Stack Exchange site – random Nov 14 '13 at 23:25
  • For the third case "non-existant repo", i'm thinking to myself, "Yeah, i know i want to create one remotely." Any thoughts? – Robbie Smith Mar 26 '14 at 18:41
  • @RobbieSmith yes, you can create on in command-line through the GitHub API: http://developer.github.com/v3/repos/#create – VonC Mar 26 '14 at 19:35
  • i ended up creating a php script on the remote server to make the dir and do a git init --bare. THEN i could do the git push -u origin master stuff.. Duh moment, it's it plugged in. – Robbie Smith Mar 26 '14 at 20:50
  • Actually in my case this was caused by having two github accounts/users - and git (CLI) was trying to use the wrong user when committing (hence the permission problem) – am_ Sep 27 '16 at 19:25