Connect Azure DevOps Repo to SourceTree

In this article, we will be going to learn how to connect Azure DevOps Repos with SourceTree.

Sourcetree is a tool that simplifies connecting your Git repositories. Using SourceTree you can visualize and manage your repositories through GUI.


Generate git credentials


For connecting SourceTree, we need credentials of Azure DevOps repo. Follow the steps to generate credentials:

Step 1) Go to your branch


Visit your branc


Step 2) Click the clone button




Step 3) Click Generate Git Credentials (we are using https instead of ssh)



Step 4) Copy your username and password and save them somewhere because you won't get it again.




Add Azure DevOps git account to SourceTree


Step 1) Open SourceTree and click on Account.




Step 2) Click Add to attach the new account and then add the following details


Host Choose Azure DevOps
url https://[[yourdomain]] Where [[yourdomain]] is your DevOps domain
Auth Type Keep default value
Username Your username
Password Your password
Protocol https



Clone repo to SourceTree

We have multiple ways to clone the repo. The first method is to clone by adding URL manually. In this method, we clone the repo by providing a repo URL.

Step 1) Open SourceTree and click on new and then select "Clone from URL"



Step 2) Enter the source URL which we get from DevOps

Note: If your cloned URL is in the format of https://<<yourdomain>> then use https://<<yourusername>>




It will ask you to provide your username and password to authenticate.

Step 3)  After authentication, click clone.





The second method to clone the repo is as follows:

Step 1) Open SourceTree and click on Remote




Step 2) Click clone

Your cloned repo is ready to create a branch,  do push, pull and commit.



Leave a Comment