---
title: "How to connect TFS Online using PAT or OAUT?"  
description: "How to connect TFS Online using PAT or OAUT?"  
author: "Revati S Misra"  
published: 2023-08-02  
updated: 2023-08-03  
canonical: https://www.mindstick.com/forum/159437/how-to-connect-tfs-online-using-pat-or-oaut  
category: "troubleshooting"  
tags: ["sharepoint", "troubleshooting", "networking"]  
reading_time: 3 minutes  

---

# How to connect TFS Online using PAT or OAUT?

How to [connect](https://www.mindstick.com/articles/12810/how-to-connect-tablet-to-external-monitor-or-flat-screen-tv-using-computer-adapters) [TFS](https://www.mindstick.com/forum/440/tfs-installation-and-configuration-using-vs-2010) [Online](https://www.mindstick.com/articles/13083/benefits-of-students-who-can-get-online-assignment) using PAT or OAUT?

## Replies

### Reply by Aryan Kumar

Sure, here are the steps on how to connect TFS Online using PAT or OAUT:

## Using a PAT

1. Go to the Azure DevOps: https://dev.azure.com/ website.
2. Sign in to your account.
3. Click on your profile picture in the top right corner of the page.
4. Select **Personal access tokens** from the menu.
5. Click on the **Create PAT** button.
6. Enter a name for your PAT.
7. Select the permissions that you want to grant to your PAT.
8. Click on the **Create** button.
9. Copy the PAT value.
10. In Visual Studio Code, open a local folder in Visual Studio Code.
11. Click on the **Source Control** icon in the Activity Bar.
12. Click on the **Team Explorer** button.
13. In the **Team Explorer** pane, click on the **Connect** button.
14. In the **Connect to Team Foundation Server** dialog box, select the **Personal Access Token** option.
15. Paste the PAT value that you copied in step 9.
16. Click on the **Connect** button.

## Using OAUT

1. Go to the Azure DevOps: https://dev.azure.com/ website.
2. Sign in to your account.
3. Click on the **Authorize** button in the top right corner of the page.
4. In the **Authorize** dialog box, select the **Personal access token** option.
5. Click on the **Authorize** button.
6. Copy the OAUTH token value.
7. In Visual Studio Code, open a local folder in Visual Studio Code.
8. Click on the **Source Control** icon in the Activity Bar.
9. Click on the **Team Explorer** button.
10. In the **Team Explorer** pane, click on the **Connect** button.
11. In the **Connect to Team Foundation Server** dialog box, select the **OAuth** option.
12. Paste the OAUTH token value that you copied in step 6.
13. Click on the **Connect** button.

Once you have connected to TFS Online, you will be able to see all of the projects that are available in your organization. You can also open and work on files in these projects.

Here are some additional things to keep in mind when connecting TFS Online using PAT or OAUTH:

- You will need to have a PAT or OAUTH token in order to connect to TFS Online.
- The PAT or OAUTH token value is a secret, so you should keep it safe.
- You can also connect to TFS Online using the `tf.exe` command from the command line.


---

Original Source: https://www.mindstick.com/forum/159437/how-to-connect-tfs-online-using-pat-or-oaut

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
