Troubleshoot connecting to a project
Azure DevOps Services | Azure DevOps Server 2022 | Azure DevOps Server 2020 | Azure DevOps Server 2019 | TFS 2018
As a first step in resolving connectivity issues with Azure DevOps, complete the following steps:
Sign out of your browser. To do so, select the Visual Studio sign out link.
Delete the cookies in your browser. To delete cookies in most browsers, select Ctrl+Shift+Del.
Open Internet Explorer and delete the browser cookies. The Visual Studio IDE uses Internet Explorer cookies.
Close all browsers and close the Visual Studio IDE.
Use a private browser session to retry the connection. If the issue is with the Visual Studio IDE, remove the connection, and then readd it.
Troubleshoot signing in
Two types of identities can sign in: Microsoft accounts and Azure Active Directory (Azure AD) accounts. Depending on your account, you might experience one of the following errors.
401 - Not Authorized
The most common error page is the 401 Not Authorized error, which occurs when your identity doesn't have permissions to enter an organization. See the following common reasons for the error:
- Your identity isn't a member of the organization.
- Your identity has an invalid or missing license assignment.
- Your identity doesn't have enough memberships to access the resource. For example, membership to the Reader/Contributors group.
- Your identity is a B2B guest in the tenant, and the invitation hasn't been accepted.
If you think you're a member of the organization, but are blocked by this error page, contact Support.
Your work or school Azure AD account doesn't have access, but your personal Microsoft account does.
401 - Work or school, or Personal account
A highly specific 401 error case. In this case, both a personal Microsoft account and a work or school account (Azure AD) that have the same sign-in address exist. You've signed in with your work or school account, but your personal account is the identity with access to the organization.
In some cases, you might not know you have two identities with the same sign-in address. The work or school Azure AD account might have been created by an administrator when you were added to Office365 or Azure AD.
To sign out of your current work or school Azure AD account, select Sign in with your personal MSA account, and then sign in by using your personal Microsoft account. After authentication, you should have access to the organization.
- If you can´t access to the organization, make sure that your Azure Active Directory still exists and that your work or school account is in the Azure AD tenant.
To avoid seeing this prompt, you can rename your Microsoft account. Then, only one identity, your work or school account, or Azure AD account, uses your sign-in address.
Your personal Microsoft account doesn't have access, but your Azure AD account does. This scenario is an opposite version of the 401 error page. In this case, the personal account (Microsoft account identity) doesn't have access to the organization and the work or school account (Azure AD identity) does. The same guidance from Scenario 1 applies, but in reverse.
401 - Work or school, or Personal account
When you get redirected back to the original sign-in page, we recommend that you clear all cookies, and then reattempt to sign in. If that doesn't fix the issue, contact Support.
Troubleshoot Azure DevOps Server connectivity
Here's a list of the most frequently reported connection problems and what to do about them. Complete the list in the order indicated.
Verify that you have the required permissions.
If the errors that you receive indicate read-only or blocked actions, you might not have permissions to act on the data.
Verify that your computer is connected to the network and that it can access network resources.
Verify that Azure DevOps Server hasn't been taken offline. Talk with your Azure DevOps Server administrator.
Check whether your project has been moved to another project collection in Azure DevOps Server. If it has been moved, you must create a connection to the new server name.
For additional troubleshooting tips, see TF31002: Unable to connect to this Azure DevOps Server.
When you use two or more organizations that are linked to Azure AD, the sign-out function might not work as expected. For example, you can't switch between different organizations to connect to multiple organizations that are linked to directory tenants.
When this problem occurs, a blank screen flashes several times. Then, one of the following error messages appears after you connect to or add a new connection in the Connect to Azure DevOps Server dialog box:
TF31003: Either you have not entered the necessary credentials, or your user account does not have permission to connect to the Azure DevOps Server
TF31002: Unable to connect to this Azure DevOps Server
To resolve this issue, apply Visual Studio 2013.2 or install a later version from the Visual Studio download website.
Another solution is to delete your browser cookies. For more information, see the support article You can't switch between different organizations in Visual Studio Codespaces.
Connect to Azure DevOps Server with Secure Sockets Layer
If you connect to an Azure DevOps Server instance that has Secure Sockets Layer (SSL) configured, install a certificate and clear the client cache. For details, see Set up HTTPS with Secure Sockets Layer (SSL) for Azure DevOps Server - Configuring client computers.
Clear the cache on client computers
When the on-premises Azure DevOps Server configuration changes, such as when you move or split a project collection, clear the cache.
Sign in to your client computer for Azure DevOps Server by using the credentials of the user whose cache you want to clear.
Close any open instances of Visual Studio.
Open a browser and go to one of the following folders, depending on the operating system your computer runs on:
Windows 10 Drive:\Users<i>UserName\AppData\Local\Microsoft\Team Foundation\6.0\Cache
Windows 8 Drive:\Users<i>UserName\AppData\Local\Microsoft\Team Foundation\4.0\Cache
Windows 7 or Windows Vista Drive:\Users<i>UserName\AppData\Local\Microsoft\Team Foundation\2.0\Cache
Delete the contents of the Cache directory, including all subfolders.
Submit and view feedback for