How to Logout After Logging in Using ms-avd:connect Command (Remote Desktop Client)?

DILIP KUMAR 20 Reputation points
2025-01-22T06:19:42.7633333+00:00

I am using the following command to connect to Azure Virtual Desktop (AVD):

ms-avd:connect?workspaceId=1638e073-63b2-46d8-bd84-ea02ea905467&resourceid=a0a0a0a0-bbbb-cccc-dddd-e1e1e1e1e1e1&username=****@contoso.com&version=0**

When I run this command, it opens a Microsoft login window asking for a password. After entering the credentials, it successfully logs in and launches the app.

However, if I run the command again, it does not ask for the password and directly connects. This indicates that some login information is cached or stored.

My questions are:

  1. Where is this login information stored?
  2. How can I log out completely or clear this cached login so that the system asks for credentials again on the next attempt?

I have tried checking Windows Credential Manager and clearing browser cookies, but the behavior persists.

Any guidance on how to fully log out or clear the stored session for the ms-avd:connect command would be appreciated!

Azure Virtual Desktop
Azure Virtual Desktop
A Microsoft desktop and app virtualization service that runs on Azure. Previously known as Windows Virtual Desktop.
1,673 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Srinud 3,840 Reputation points Microsoft Vendor
    2025-01-22T15:50:11.99+00:00

    Hi DILIP KUMAR,
    Thank you for reaching out to us on the Microsoft Q&A forum.
    The login information for Azure Virtual Desktop (AVD) is typically stored in the Windows Credential Manager as a generic credential.
    To fully log out or clear the cached login information, please follow these steps:

    1. Access the Credential Manager via the Control Panel or by searching for "Credential Manager" in the Start menu.
    2. Select "Windows Credentials" and locate the entry associated with your AVD connection, which will begin with "RDPClient".
    3. To clear the cached login information, select the entry and click "Remove". This action will delete the stored credentials, and you will be prompted to enter your username and password the next time you connect.

    Please find the below document for more information:
    https://learn.microsoft.com/en-us/azure/virtual-desktop/users/client-features-windows?pivots=remote-desktop-msi#manage-user-accounts


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.