Azure Sourcetree

Sourcetree for Windows; SRCTREEWIN-12500; Unable to add Azure DevOps Remote Account using SourceTree 3.1.3. To generate a token, login to Azure Dev Ops. On the top right menu, click on the circle with your initials and select 'Security'. Generate a new one token. Give it a name, e.g. SourceTree (not important), and copy the token to be used with SourceTree. The goal of this article is to guide users to generate and load SSH keys into SourceTree using PuTTY. To generate an SSH Key, select Tools Create or Import SSH Keys. This window should pop up: 2. Click Generate, and move the mouse randomly until a key is generated: 3. A public key and a private key should appear. Browse other questions tagged git azure-devops atlassian-sourcetree or ask your own question. The Overflow Blog A look under the hood: how branches work in Git. What international tech recruitment looks like post-COVID-19. Featured on Meta Stack Overflow for Teams is now free for up to 50 users, forever. From Sourcetree, click the Branch button. Depending on whether you have a Git or Mercurial repository, you see a different popup for creating a new branch. From the New Branch or Create a new branch field, enter wish-list for the name of your branch. Click Create Branch or OK. From Sourcetree, click the Show in Finder button. The directory on.

In this short post, I will show you how you can connect SourceTree with Azure DevOps. That way, you can work with your GIT repositories using the best of both worlds.

I like using SourceTree in my development teams since it is an easy interface. Another advantage is that it is available for both Windows and Mac OS. Last but not least; it supports the Gitflow Workflow, which is especially great for release-based projects.


Back in 2018, Microsoft renamed VisualStudio Online into Azure DevOps. It sounds more catchy and it indicates its purpose more; enabling developer teams to take care of rolling out their software independently.

But changing a name for an online service also means changing the URL. And this is where a lot of people get mixed up on what to use for their GIT repo URL.

Azure Sourcetree

Add in a snuff of confusion by changing the access for external tools from username password to a Personal Access Token (PAT) and you have a lot of people getting confused.

Because is more annoying than if you can’t get your favorite GIT client to work with a GIT repo that you want to clone.

I got this working via the following steps:

  1. Create a PAT in Azure DevOps (
  2. Make sure you copy the generated PAT as you won’t be able to view it again
  3. On Source Tree, go to add account and select Azure DevOps
  4. for the host, I used https://{organisation} as the new URL format for Azure DevOps didn’t work
  5. enter the generated PAT as username
  6. use the PAT you just generated for the password as well

After this, you can get the URL of your repository and add your repo to Sourcetree as described on the SourceTree help page.

The credentials appear to be ignored?

If somehow your Sourcetree doesn’t seem to be using the right PAT credentials when you try to clone your repo, force Sourcetree to use the credentials by prefixing the URL with them:


Using these steps, SourceTree will force using the PAT as credentials for the repo and you can clone and work on the repo directly.

Sourcetree Azure Devops Ssh

Somehow, I couldn’t get the username — PAT as a password combination working. I found out this route and it works for me.

Azure source repository

Please note

At the time of writing, there are some things you should know. I didn’t use them in my instructions to spare them for you and because you probably — like me — just want to get to speed and work with your repo:

  • The old “visualstudio” URL still needs to be / can be used for closing
    (read more here): https://*username*
  • Apparently, you can use the new URL alongside with your PAT, but you need a hacky way to do it (read more here)


Sourcetree Azure Devops On Premise

Hopefully, this post helped you save some time by showing you how to connect SourceTree with Azure DevOps.

Sourcetree Azure Devops Username

Once you have them connected, they will play nice together. I found them to be a very nice couple with some great advantages:

  • SourceTree can be used by both Mac and Windows users on your team and makes your team talk in the same GIT lingo and use Git WorkFlow.
  • Whereas Azure DevOps lets you work on your product in an Agile manner, with planning boards, automated flows via Pipelines, and GIT repositories.

Code Hard, Ship harder 🔥