Run WinSCP as a Windows Service with AlwaysUp

How to Run a WinSCP Script as a Windows Service with AlwaysUp

Reliably schedule your WinSCP Script to run whenever your server is up — even if no one ever logs on. Ensure that your FTP solution works 24x7 in the background


Last Updated on June 2, 2026

WinSCP is a free SFTP/SCP/FTP client. In addition to sporting a GUI for conventional file transfer usage, WinSCP also features very powerful scripting capabilities to facilitate unattended automation.


To set up WinSCP as a Windows Service with AlwaysUp:

  1. Download and install WinSCP, if necessary:

    Install WinSCP

  2. Download and install AlwaysUp, if necessary.

  3. Start AlwaysUp.

  4. Select Application > Add to open the Add Application window:

    Add Application

  5. On the General tab:

    • In the Application field, enter the full path to the WinSCP command line program, WinSCP.com. If you installed WinSCP in the default location, this is:

      C:\Users\[USER-NAME]\AppData\Local\Programs\WinSCP\WinSCP.com

      where [USER-NAME] is the name of the Windows account where you installed WinSCP.

    • In the Arguments field, enter the parameters to WinSCP.com.

      Since we want to run our sample script, we enter /script= followed by the full path to our script. Be sure to quote the entire path to your script if it contains a space, as ours does.

    • In the Start the application field, choose Automatically, but shortly after the computer boots. With this setting, WinSCP.com will start a couple of minutes after boot — after all your machine's critical networking services are up and running.

    • Finally, in the Name field, enter the name that you will call the application in AlwaysUp. We suggest WinSCP Script but you can specify another name if you like.

    WinSCP Windows Service: General Tab

  6. Click over to the Logon tab and enter the username and password of the Windows account in which you installed and configured WinSCP. WinSCP must run in this account so that it can find its settings.

    WinSCP Windows Service: Logon Tab

  7. Switch to the Restart tab:

    • To run your script every hour, on the hour, (instead of the default, 24x7) select the Not immediately and On the next hour options as we have done below.

    • Also, we recommend checking the Minimize event logging and Don't panic if the application completes very quickly boxes. With those settings in place, AlwaysUp will do a better job of managing WinSCP as it goes up and down multiple times per day.

    WinSCP Windows Service: Restart Tab

  8. And finally, switch to the Extras tab:

    • If your computer is configured to go into a low-power state after a period of inactivity, check the Prevent the computer from automatically going to sleep box to avoid that behavior while the WinSCP service is active.

    • To capture the output from your script, check the Capture output to this log file box and enter the full path to a suitable text file. Set the options beneath to prevent the file from growing too large.

    WinSCP Windows Service: Extras Tab

  9. We're done configuring your WinSCP script to run as a service so click the Save button to record your settings. In a couple of seconds, an application called WinSCP Script will show up in the AlwaysUp window. It is not yet running though:

    WinSCP Windows Service: Created

  10. To start your WinSCP script, choose Application > Start "WinSCP Script". The state should transition to "Running" and your script will be executed in the background:

    WinSCP Windows Service: Running

    Once your script has done its work and exited, the state will transition to "Waiting" in AlwaysUp. It will start again on the next hour (as configured):

    WinSCP Windows Service: Waiting

    Now would be a great time to review the text file capturing output to ensure that the script is working as expected.

  11. That's it! Next time your computer boots, WinSCP will run as scheduled, without anyone having to log on to run your script manually at the desired times.

    We encourage you to edit WinSCP in AlwaysUp and check out the many other settings that may be appropriate for your environment. Boost priority, send an email when the computer boots, and much more.


WinSCP not working properly as a Windows Service?

  • Consult the AlwaysUp Troubleshooter — our online tool that can help you resolve the most common problems encountered when running an application as a Windows Service.

  • From AlwaysUp, select Application > Report Activity > Today to bring up an HTML report detailing the interaction between AlwaysUp and WinSCP. The AlwaysUp Event Log Messages page explains the more obscure messages.

  • Browse the AlwaysUp FAQ for answers to commonly asked questions and troubleshooting tips.

  • Contact us and we will be happy to help!

Our 14,000+ customers include...
AlwaysUp is fully compatible with Windows 11 AlwaysUp is fully compatible with Windows Server 2025
Over 97,000 installations, and counting!
 
AlwaysUp is number 1! Run as a Service with AlwaysUp

Rock-solid for the past 20+ years!