Install the Remote Desktop client for Windows on a per-user basis with Intune or Configuration Manager
You can install the Remote Desktop client for Windows on either a per-system or per-user basis. Installing it on a per-system basis installs the client on the machines for all users by default, and administrators control updates. Per-user installation installs the application to a subfolder within the local AppData folder of each user's profile, enabling users to install updates without needing administrative rights.
When you install the client using msiexec.exe
, per-system is the default method of client installation. You can use the parameters ALLUSERS=2 MSIINSTALLPERUSER=1
with msiexec
to install the client per-user, however if you're deploying the client with Intune or Configuration Manager, using msiexec
directly to install the client causes it to be installed per-system, regardless of the parameters used. Wrapping the msiexec
command in a PowerShell script enables the client to be successfully installed per-user.
Prerequisites
In order to install the Remote Desktop client for Windows on a per-user basis with Intune or Configuration Manager, you need the following things:
Download the latest version of the Remote Desktop client for Windows.
Supported Windows devices managed by Microsoft Intune or Configuration Manager with permission to add applications.
For Intune, you need a local Windows device to use the Microsoft Win32 Content Prep Tool.
Install the Remote Desktop client per-user using a PowerShell script
To install the client on a per-user basis using a PowerShell script, select the relevant tab for your scenario and follow the steps.
Here's how to install the client on a per-user basis using a PowerShell script with Intune as a Windows app (Win32).
Create a new folder on your local Windows device and add the Remote Desktop client
.msi
file you downloaded.Within that folder, create a PowerShell script file called
Install.ps1
and add the following content, replacing<RemoteDesktop>
with the filename of the.msi
file you downloaded:msiexec /i <RemoteDesktop>.msi /qn ALLUSERS=2 MSIINSTALLPERUSER=1
In the same folder, create a PowerShell script file called
Uninstall.ps1
and add the following content:$productCode = (Get-WmiObject -Class Win32_Product | Where-Object {$_.Name -eq 'Remote Desktop' -and $_.Vendor -eq 'Microsoft Corporation'}).IdentifyingNumber msiexec /x $productCode /qn
In the same folder, create a PowerShell script file called
Detection.ps1
and add the following content:If (([string](Get-ChildItem Registry::HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall | Where-Object {$_.GetValue('DisplayName') -eq 'Remote Desktop'})) -and (Get-WmiObject -Class Win32_Product | Where-Object {$_.Name -eq 'Remote Desktop' -and $_.Vendor -eq 'Microsoft Corporation'})) { Write-Host "Microsoft Remote Desktop client is installed" exit 0 } else { Write-Host "Microsoft Remote Desktop client isn't installed" exit 1 }
Follow the steps in Prepare Win32 app content for upload to package the contents of the folder into an
.intunewin
file.Follow the steps in Add, assign, and monitor a Win32 app in Microsoft Intune to add the Remote Desktop client. Here's some of the information you need to specify during the process. You can leave the rest of the settings as default or update them as needed.
Parameter Value/Description Name Enter Remote Desktop
.Publisher Enter Microsoft Corporation
.Install command powershell.exe -ExecutionPolicy Bypass -WindowStyle Hidden -File .\Install.ps1
Uninstall command powershell.exe -ExecutionPolicy Bypass -WindowStyle Hidden -File .\Uninstall.ps1
Install behavior Select User. Operating system architecture Select 64-bit or 32-bit, depending on the version of the Remote Desktop client you downloaded. Minimum operating system Select the minimum version of Windows in your environment and that is in support. Detection rules format Select Use a custom detection script. Detection script file Select the file Detection.ps1
you created earlier.
Next steps
Learn more about the Remote Desktop client at Use features of the Remote Desktop client for Windows.