Launch Apps Automatically When Admins Sign In via RDP
A practical guide to auto-starting programs at RDP logon on Windows Server and RDS, using the Run key, Startup folder, scheduled tasks, and Group Policy.
When you manage a Windows VPS over Remote Desktop, you often want a specific program to launch the moment an administrator signs in: a monitoring console, a management tool, a line-of-business app, or a dashboard. On a standalone server or a Remote Desktop Services (RDS) session host, Windows gives you several ways to do this. Each behaves differently depending on whether the app should start for every user or just one, and whether it needs a desktop session or not. This guide walks through the practical options and when to reach for each.
Decide the scope first
Before you configure anything, answer two questions. First, should the program start for every user who logs on, or only for a specific account? Second, does it genuinely need an interactive RDP session, or could it run as a service instead? Autostart-at-logon methods only fire when someone actually signs in over RDP and reaches the desktop — they do nothing while the server sits at the sign-in screen. If you need something running 24/7 regardless of who is connected, a Windows service or a scheduled task triggered at startup is the better fit.
Option 1: The Startup folder (simplest)
Dropping a shortcut into a Startup folder is the least technical approach and is easy to audit later. There are two locations:
- Per user:
shell:startup→%AppData%\Microsoft\Windows\Start Menu\Programs\Startup - All users:
shell:common startup→%ProgramData%\Microsoft\Windows\Start Menu\Programs\Startup
From a PowerShell session on your VPS, create a shortcut for all users:
$startup = "$env:ProgramData\Microsoft\Windows\Start Menu\Programs\Startup"
$shell = New-Object -ComObject WScript.Shell
$link = $shell.CreateShortcut("$startup\MyApp.lnk")
$link.TargetPath = "C:\Apps\MyApp\MyApp.exe"
$link.Save()
The program then launches for anyone who logs on interactively, including over RDP. The trade-off: it runs with the signed-in user's rights, and a user can remove the shortcut from their own per-user folder.
Option 2: The registry Run key
The Run keys start a program at logon and are harder for ordinary users to tamper with. Use HKLM for all users or HKCU for the current user:
Set-ItemProperty -Path "HKLM:\Software\Microsoft\Windows\CurrentVersion\Run" `
-Name "MyApp" -Value '"C:\Apps\MyApp\MyApp.exe"'
Entries under HKLM require administrator rights to change, which makes this a good choice on a shared RDS host where you don't want users editing the autostart list. Wrap the path in quotes if it contains spaces. Avoid the RunOnce key unless you deliberately want a one-time launch — it deletes the value after it fires.
Option 3: Scheduled task triggered at logon
Task Scheduler is the most flexible option and the one I reach for most on managed VPS servers. It can target a specific user, delay the launch, run with highest privileges, and survive reboots cleanly. Create a logon-triggered task in PowerShell:
$action = New-ScheduledTaskAction -Execute "C:\Apps\MyApp\MyApp.exe"
$trigger = New-ScheduledTaskTrigger -AtLogOn
$set = New-ScheduledTaskSettingsSet -StartWhenAvailable
Register-ScheduledTask -TaskName "Start MyApp at logon" `
-Action $action -Trigger $trigger -Settings $set -RunLevel Highest
To scope it to one account, add -User "DOMAIN\\admin" to the trigger. A short delay (-Delay on the trigger via XML, or a built-in delay) helps when the app depends on the network or a mapped drive that isn't ready the instant the desktop appears over RDP.
Option 4: Group Policy on RDS
On an RDS deployment or any domain-joined estate, Group Policy keeps autostart consistent across session hosts without touching each server by hand. Two useful settings:
- Run these programs at user logon under User Configuration → Administrative Templates → System → Logon.
- Group Policy Preferences → Windows Settings → Shortcuts, to deploy a Startup-folder shortcut with item-level targeting (for example, only to a specific group).
RDS also supports a RemoteApp model and a per-collection initial program, where connecting launches a single published application instead of a full desktop — worth considering if the app is the reason users connect.
Handling the RDP session nuance
Remember that a reconnect to an existing, disconnected session does not re-trigger logon autostart — the program only starts on a fresh sign-in. If admins routinely disconnect rather than sign out, the app will already be running when they reconnect, which is usually what you want. Also confirm the executable doesn't need elevation it won't get: a Startup-folder or HKCU launch runs as a standard token, so UAC-sensitive apps belong in a scheduled task with -RunLevel Highest.
Choosing and verifying
For a quick, visible launch, use the Startup folder. For a locked-down all-users entry, use the HKLM Run key. For anything needing elevation, delays, or a specific account, use a scheduled task. For a fleet of RDS hosts, use Group Policy. After configuring, test by signing out of your RDP session completely and reconnecting — don't just disconnect — and confirm the process appears:
Get-Process MyApp -ErrorAction SilentlyContinue
Keep a note of which method you used; mixing several for the same app is the most common cause of a program that stubbornly launches twice at every logon.
Run this on your own Windows VPS
Spin up a fully managed Windows VPS from WindowsVPS in minutes — full Administrator access over RDP, NVMe storage and global regions.
Related Articles
Ready to deploy your server?
Windows or Linux VPS — up and running in under 60 seconds.