An Azure service that is used to provision Windows and Linux virtual machines.
Use the following checks and fixes, in order, for the "Your credentials did not work" RDP error to an Azure Windows VM.
- Confirm the correct account format
The VM can only validate:- Local accounts:
ComputerName\UserName(example:SQL1\Admin4798) - Domain accounts:
DomainName\UserName(example:CONTOSO\peterodman)
- Before promotion:
DC1\DCAdmin - After promotion:
CORP\DCAdmin(localDC1\DCAdminno longer exists)
- Local accounts:
- If using Microsoft Entra ID (Azure AD) sign-in
When RDP-ing with Microsoft Entra credentials, the following must be true:- The client PC is Microsoft Entra joined or hybrid joined to the same directory as the VM.
- If the client is only Microsoft Entra registered, credentials must be entered as:
AzureAD\UPN(for example,AzureAD\******@contoso.com). - The AADLoginForWindows extension must still be installed on the VM.
- Reset the local administrator password from Azure portal
If unsure whether the local admin password is correct or the account is locked:- In the Azure portal, open the VM.
- In the left pane, under Help, select Reset password.
- Set Mode to Reset password.
- Enter a local administrator username and a new password.
- Select Update.
- Try RDP again using
ComputerName\UserNameand the new password.
- Check that the account has Remote Desktop sign-in rights
If the error persists even with correct credentials, the account may not be allowed to sign in via RDP:- Only members of Administrators or Remote Desktop Users on the VM can sign in via RDP.
- As a workaround, sign in with a local or domain administrator (after resetting its password as above), then:
- Open Computer Management → System Tools → Local Users and Groups → Groups → Remote Desktop Users.
- Add the desired user or group.
- If using Entra ID + Azure RBAC for RDP
For Entra-based RDP, also verify:- The user has Virtual Machine Administrator Login or Virtual Machine User Login role on the VM or its resource group.
- Device and SSO state on the client via
dsregcmd /statusshows:-
AzureAdJoined : YES -
AzureAdPrt : YES
-
- Review Event Viewer → Applications and Services Logs\Microsoft\Windows\AAD\Operational on the VM for detailed sign-in errors.
If all the above are correct and the error still appears, use the general RDP troubleshooting flow (reset RDP configuration, verify NSG/firewall, check boot diagnostics, etc.) from the referenced articles, but the credential format and account rights are the primary causes for this specific message.
References:
- Troubleshooting specific RDP error messages to a Windows VM in Azure
- Troubleshoot Remote Desktop connections to an Azure virtual machine
- Sign in to Windows virtual machine in Azure using Microsoft Entra ID and Azure Roles Based Access Control
- Sign in to an Azure Arc-enabled server using Microsoft Entra ID and Azure Roles Based Access Control