Install OpenSSH server in Windows 11

Stefan
Install OpenSSH server in Windows 11

If you plan to install OpenSSH server in Windows 11, this article will tell you how to do it.

SSH is a protocol. It allows you to remotely connect to a computer and execute commands on it over an encrypted connection. We call this a “shell” because it provides a secure environment for remote management.

OpenSSH is an open-source variant of the SSH protocol that can be used by everyone. OpenSSH is available as a server in Windows 11 to install. This is useful if you use Windows 11 as a server environment, a web server for example.

Install OpenSSH server in Windows 11

Right-click on the Start button. In the menu click on “settings”. In the settings, click on “apps”.

Because OpenSSH is an optional feature in Windows 11, click on “optional features”.

Add optional features in Windows 11

Click on “show features” to add an optional component.

Show functions

Search for “openssh” in the search field and click “OpenSSH server”. Click next to proceed to installation.

Install OpenSSH server in Windows 11

Confirm again by clicking “install”.

Install OpenSSH server

OpenSSH server is then installed in Windows 11.

OpenSSH server is being installed

After installation, you will need to make changes to the configuration file for OpenSSH. This “openssh_config” configuration file can be found at the following hidden location:

C:\ProgramData\ssh

However, before any files are stored here, the SSH service must first be started. Right-click on the Start button. Click “run” in the menu. In the run window type: services.msc

In the list of services, search for:

  • OpenSSH SSH Server (abbreviated: sshd)
  • OpenSSH Authentication Agent (abbreviated: ssh-agent)

Start both services and, if necessary, change the service status to automatic so that they are started when you log in to Windows 11.

Read also
Change default browser in Windows 11? This is how!

Start OpenSSH server in Windows 11

You can now edit the “sshd_config” file in the location mentioned earlier. If you make any adjustments to this, you will need to restart the services.

sshd_config file

If everything is properly installed and configured, you can use the netstat command:

netstat -nao

check if port “22” is open on “localhost”. Possible exceptions in the Windows or external firewall must be configured to remotely access port 22 SSH.

port 22 open ssh windows 11

I hope this helped you. Thank you for reading!


Problem solved?


Help other people too.
Share this article on a website, forum or via social media.

Join our new computer forum for questions and computer help.
Do you have a computer question?

The email address will not be published. Required fields are marked with *