Remote Desktop

Enable Remote Desktop using Command Prompt or PowerShell

Enable Remote Desktop using Command Prompt or PowerShell

If you want to use the Remote Desktop feature without opening the Windows Settings panel, then you can enable Remote Desktop using Command Prompt or Windows PowerShell. If you have a remote desktop client on your mobile or another computer, you will be able to connect it and use your PC remotely.

Remote Desktop is a well-known facility of Windows computer that lets you connect two computers or mobile so that an individual can access another computer remotely. You can fix some problems on the computer via mobile or do other jobs according to your requirements. You need a Remote Desktop client like Microsoft Remote Desktop or so on your mobile to connect two devices.

It is possible to enable to disable Remote Desktop Windows Settings. You need to head to System > Remote Desktop to access the option. However, let's assume that the Windows Settings panel is not opening due to some reasons, and you need to turn on the Remote Desktop feature. Then you can use this method to start the Remote Desktop using the command line.

Enable Remote Desktop using Command line

To enable Remote Desktop using Command Prompt and Windows PowerShell, follow these steps-

  1. Open Command Prompt or PowerShell with administrator privilege
  2. Set value of fDenyTSConnections REG DWORD to 0
  3. Add a Firewall rule
  4. Restart your computer
  5. Start using Remote Desktop in Windows 10.

The commands are not the same for Command Prompt and Windows PowerShell.

1] Enable RDP firewall using Command Prompt

To get started, open the Command Prompt with administrator privilege. You can search for it in the Taskbar search box, and click the Run as administrator option that appears on your screen. After that, enter this following command and hit Enter:

reg add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f

By default, the value of fDenyTSConnections is set to 1. This command will change the value to 0.

Next, execute the following command:

netsh advfirewall firewall set rule group="remote desktop" new enable=yes

This command will add and update three rules in the Firewall so that you can start using the Remote Desktop.

2] Enable RDP using Windows PowerShell

You need to open the Windows PowerShell with administrator privilege and enter the following command and hit Enter:

Set-ItemProperty -Path 'HKLM:\System\CurrentControlSet\Control\Terminal Server'-name "fDenyTSConnections" -Value 0

This command will change the fDenyTSConnections value to 0. Now, you need to execute the following command to add rules in the Firewall:

Enable-NetFirewallRule -DisplayGroup "Remote Desktop"

After that, you will be able to use Remote Desktop in Windows 10.

In case you want to disable Remote Desktop using Command Prompt and Windows PowerShell, you need to enter these steps.

Remote Desktop option is greyed out on Windows 10

Disable Remote Desktop using Command Prompt or PowerShell

To disable Remote Desktop using Command Prompt and Windows PowerShell, follow these steps-

  1. Open Command Prompt or PowerShell with administrator privilege
  2. Set value of fDenyTSConnections REG DWORD as 1
  3. Add a Firewall rule
  4. Restart computer.

To know more, you need to read on.

Disable Remote Desktop using Command Prompt

You need to set the default value of fDenyTSConnections as 1. For that, use this command-

reg add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 1 /f

Now you need to remove rules from the Firewall. For that, use this command-

netsh advfirewall firewall set rule group="remote desktop" new enable=No

Disable Remote Desktop using PowerShell

You need to change the value of fDenyTSConnections as 1. You can do that by using this command-

Set-ItemProperty -Path 'HKLM:\System\CurrentControlSet\Control\Terminal Server'-name "fDenyTSConnections" -Value 1

The second command will let you remove the rules from the Firewall:

Disable-NetFirewallRule -DisplayGroup "Remote Desktop"

That's all! I hope this simple tutorial will be helpful for you.

Instalați cel mai recent joc de strategie OpenRA pe Ubuntu Linux
OpenRA este un motor de jocuri de strategie în timp real Libre / Free care recreează primele jocuri Westwood, cum ar fi clasicul Command & Conquer: Re...
Instalați cel mai recent Dolphin Emulator pentru Gamecube și Wii pe Linux
Emulatorul Dolphin vă permite să jucați jocurile alese de Gamecube și Wii pe computerele personale Linux (PC). Fiind un emulator de joc liber disponi...
Cum se folosește GameConqueror Cheat Engine în Linux
Articolul acoperă un ghid despre utilizarea sistemului de înșelăciune GameConqueror în Linux. Mulți utilizatori care joacă jocuri pe Windows folosesc ...