This is going to be a super quick tutorial about how to access a Windows environment through ssh.

Step 1. Install cygwin, and make sure openssh and cygrunsrv packages are installed:

Make sure openssh is selected for installation

Make sure cygrunsrv is selected for installation

Step 2. Start cygwin and run ssh-host-config to configure ssh:

Run ssh-host-config to configure ssh

Step 3. Run cygrunsrv -S sshd to start sshd as a Windows service:

Run cygrunsrv -S sshd to start sshd

Step 4. Ssh into Windows using your favorite ssh client

Use putty to ssh into Windows

You can even set this up for your local workstation (if it happens to be Windows). Then you can forget about cmd.exe or PowerShell and use a real shell locally. Until next time.


January 27, 2014, 19:16

Another alternative that I would recommend is 'BitVise SSH Server'. It is free for personal use, but, unfortunately, not open source. By default, it is configured to run as a service at startup. I can even SSH to a freshly booted machine and log in using the SSH shell (I use mRemote / mRemoteNG [ ] on the other side to access the SSH clients -- With its tabbed interface, it is easy to deal with multiple machines simultaneously).

January 27, 2014, 22:20

Thanks for the comment, didn't know about BitVise SSH Server and mRemote. Very useful!

Chris Permalink
January 27, 2014, 21:24

Why would you use SSH on a Windows server?

January 27, 2014, 22:19

Well to remotely manage the server though ssh and to deploy updates through ssh, and transfer files very quickly through scp, as well as having a better shell!

Chris Permalink
January 30, 2014, 01:32

I am not saying there is anything wrong with SSH, just that most all management of Windows can be done with PowerShell, remotely and securely...

And for secure file transfer you could enable Secure FTP which is also built-in and configurable through PowerShell...

March 26, 2014, 15:06

For us folks that are comfortable with the bash shell, this makes working in Windows from putty or a *nix host quite convenient. Powershell has its uses, but it really isn't any more secure than scp. And, IMHO, establishing sessions with the more secure public/private rsa keys via ssh-keygen is a lot easier than having to deal with Kerberos, CredSSP or certificate.
Technet article discussing WinRM and Powershell for remote management:

Foo Permalink
January 28, 2014, 15:25

Because this particular windows machine is the only one *you* can access that can access another (linux) server through ssh? That's a real use case even if that seems a bit weird.

So with this you can ssh into windows, and then ssh into the 'target' server.

Otherwise you'd have to remote desktop into the windows machine, and then ssh from there into the target server.

Chris Permalink
January 30, 2014, 01:34

Sounds like you want to explore Remote Desktop Gateway which is included for free in Windows Server...

February 20, 2014, 05:37

Thanks Peteris for informative share! I really want to learn more about SSH for windows.

no_name Permalink
March 01, 2014, 11:40

I actually do the other way round; I got cygwin on my wintel box and from it I ssh/scp/sftp etc to UNIX boxes. Sshd/cygwin on wintel is nice if you need to admin wintels with strong UNIX background.

Acker Permalink
May 13, 2014, 18:01

Your knowledge of this subject comes through clearly in this post. I love to read this kind of post, I hope you will update it. academic assignment.

June 05, 2014, 22:25

I am not able to figure out the advantage of this?


July 18, 2014, 09:33

Is so amazing

July 28, 2014, 06:14

Ok it will be superb

September 12, 2014, 10:31

Its a great pleasure reading your post.
Its full of information I am looking for and I love to post a comment that "The content of your post is awesome" Great work.

October 28, 2014, 11:55

Oh. Thi is too hard for me. But i'll try)

Christopher Permalink
October 30, 2014, 03:17

Why do you allow links in your comments?

November 29, 2014, 08:58

Its features can be quickly and completely covering variations in design and color, sound and heat insulation and so on.

Kaur deep Permalink
December 04, 2014, 03:26

Excellent and knowledgeable links and post.thanks for sharing.
Now, The Time has come for the Happy New Year 2015. It wil bring a lot fo happinesin our life.
Happy New Year 2015
And I am sure, You wil anjoy this new year day with yoru fiends and wil send some images wishes,
New Year 2015

Happy New Year 2015 Wishes
Greetings to yoru close ones, Your friends, You lover, etc..
Happy New Year 2015 Images
Even I am waititng for that day, because it just changes our life.
Happy New Year 2015 Greetings

Happy New Year 2015 SMS
So, That's why I am commenting here to wish you a very happy new year.
Happy New Year 2015 Messages
I hope this New year 2015 wil bring success to your website. But before that Merry Christmas is coming.
Merry Christmas Quotes
It is also a big event for everyone.
Merry Christmas Pictures
Everyone knows that Christmas is a day when People seems to be very happy, they just leave all sadness behind.
Merry Christmas Wallpapers
And I am sure, you also enjoy this Merry Christmas day of 2014.
Christmas day Images

Christmas stocking
But if you are not looking out to enjoy this christmas, then you are missing out on a big thing, because it really brings happiness.
Merry Christmas Images

Merry Christmas 2014
So, what you are waiting for?
Merry Christmas 2015
Enjoy This Merry Christmas day. Cheers :).

December 08, 2014, 12:54

Articles and photos on this site is interesting. Thank you for this material

December 16, 2014, 10:59

Information on this site is helpful. I hope this site will have more progress

December 18, 2014, 15:04

super quick tutorial, found all info I was looking for, thanks.

December 22, 2014, 10:30

I hope this site will have more progress

Leave a new comment

(why do I need your e-mail?)

(Your twitter name, if you have one. (I'm @pkrumins, btw.))

Type the word "antispam_407": (just to make sure you're a human)

Please preview the comment before submitting to make sure it's OK.