During git push - Unable to access Fatal Error

While running git push origin master
I am getting below error.

remote: Permission to Sumanshu-Nankana/Docker.git denied to Sumanshu-Nankana.
fatal: unable to access ‘https://github.com/Sumanshu-Nankana/Docker.git/’: The requested URL returned error: 403

  1. Password and Username is correct (as it’s working on github.com)
  2. I tried with Public Access Token (because I have 2 Factor Auth enable)
  3. I am using https (so no ssh key concept)
  4. I am able to push using VS CODE , but unable to push using Terminal (getting this error first time - probably after enabling 2Factor Auth)

But with both password and token, I am getting same ‘Unable to access’, with token (I get some extra message as well i.e. The requested URL returned error: 403)

can anyone help me, what is wrong. Though I am

Did you make sure to give the PAT the necessary permissions when creating it?

1 Like