Client authentication error when starting Visual Studio 2015 SP3

Visual Studio-2015Azure Devops

Visual Studio-2015 Problem Overview


I just performed a clean install of Visual Studio 2015 SP3, and I'm getting this in the Output window at startup:

> We were unable to automatically populate your Visual Studio Team Services accounts. > > The following error was encountered: TF400813: Resource not available for anonymous access. Client authentication required.

I'm not using VSTS at all, nor have I configured any connections to it. (I do, however, have a connection configured to an on-premises TFS instance.)

How may I dispense with this error message? I'd like to instruct Visual Studio to never attempt a connection to VSTS at startup.

Visual Studio-2015 Solutions


Solution 1 - Visual Studio-2015

In the top right corner of Visual Studio, you will find a colored box with your name or your initials inside. Click the down arrow and then Account Settings.

In the opening window, please click "Sign out" in the upper left part of the window.

After a restart of Visual Studio and signing back in, the error should be gone.

Solution 2 - Visual Studio-2015

You can disable the auto connection on startup via the following steps:

  1. Run "Developer Command Prompt for VS2015" as Administrator.
  2. Run "tfpt connections" command from the developer command prompt.
  3. Uncheck "Automatically reconnect to last server on startup" option and apply the settings.

Note that you will get 'tfpt' is not recognized as an internal or external command, operable program or batch file if you don't have TFS Power Tools installed. You can install them from Microsoft Visual Studio Team Foundation Server 2015 Power Tools.

Solution 3 - Visual Studio-2015

This solution fixed it for me:

  1. Close Visual Studio
  2. From command line run: del %localappdata%\.IdentityService\SessionTokens.json

Solution 4 - Visual Studio-2015

Similar to the accepted solution, but I didn't have to log out. The solution for me (Visual Studio 2019) was to

  1. click the link to re-authenticate
  2. restart visual studio

After I did that (I clicked the link in #1 several times) then Git integration began to work again.

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionInteXXView Question on Stackoverflow
Solution 1 - Visual Studio-2015Basem SayejView Answer on Stackoverflow
Solution 2 - Visual Studio-2015Eddie Chen - MSFTView Answer on Stackoverflow
Solution 3 - Visual Studio-2015VedranView Answer on Stackoverflow
Solution 4 - Visual Studio-2015dasquire_nView Answer on Stackoverflow