Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Next challenges

Recent achievements

  • Global
  • Personal


  • Give kudos
  • Received
  • Given


  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Permission denied (public key) when using SourceTree, but SourceTree still registers updates

I am having an issue with the most recent version of ST for Mac OSX. I recently downloaded it and set it up successfully with my GitLab account, cloned my repos, was able to push and pull and everything was fine. Then, I started getting the Permission Denied (public key) error and became unable to use ST for pushes and pulls. Interestingly, ST would still register when pushes and pulls were necessary and I was able to do them via Terminal (and once I did, the push/pull indicators would update in ST); however, I cannot use the UI to do it. 

Things I've already tried:

Tried generating a new SSH key pair and updating GitLab with the key. 

Tried uninstalling/reinstalling ST (I did this manually, and was careful to uninstall any ancillary files that were hanging out there, then emptying the trash). After I did this, I tried to create new clones from URL; however,  For some reason, it did not recognize my SSH gitlab repo as a legitimate URL, even though it definitely is...and it must be, for my pushes and pulls to still work via Terminal.


At some level, ST must be connected to my GitLab account for it to work to the extent it does; yet, I still cannot use the UI. Can anyone help?

2 answers

0 votes
Ana Retamal Atlassian Team Aug 18, 2017


Hi Colleen, I see you already tried re-installing the program, but can you try doing a clean install? These are the steps to follow:

  1. Wipe SourceTree preferences
  2. Uninstall SourceTree.
  3. Delete the directory ~/Library/Application Support/SourceTree
  4. Get the latest SourceTree and install it. 

Let us know if this worked for you!



Can't delete comment?

Can't delete comment?

Unfortunately, it didn't work for me. I am still having the same issue. When I uninstalled the first time, I also deleted that directory; still, I tried it one more time and the problem persists.

Interestingly, I have another laptop with an older version of ST installed on it and it works fine. I have checked all of the visible settings there to make sure they are the same on this laptop. Is it possible to download older versions of ST to see if that fixes my issue? The one I have on my other laptop is

Ana Retamal Atlassian Team Aug 21, 2017

Hi! You can find older versions at SourceTree Download Archives.

Hope that helps,


Thank you. Downloading seems to have helped. I am now able to push/pull via the UI again. 

However, I am less convinced that this was a version issue--i think it was more likely a setting that I just couldn't find. Regardless, as long as it works, I am good :)

After the latest update I can Fetch/Pull/Commit but cannot Push (permission denied public key). I have checked and rechecked my ssh bitbucket settings and all is good. Pushing works perfectly fine in Terminal.

Ana's instructions above fixed my problem. Thanks!

Ana Retamal Atlassian Team Aug 21, 2017

Glad to hear it helped you, Jared!

Have a nice day,


Suggest an answer

Log in or Sign up to answer
Community showcase
Posted in Sourcetree

[dev team] Sourcetree for Windows 2019 Preview - Dark Theme

Hi folks, While the full post is over on our blog I'd like to share the dark theme we've got planned for 2019 here directly as well to keep the discussion going.  The ...

3,280 views 19 18
Join discussion

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you