|

Fix WinSCP Network Error: Connection Refused Or Timed Out (2026)

Quick answer

  • If other programs connect but WinSCP does not, add winscp.exe as an exception in Control Panel > System and Security > Windows Defender Firewall > Allow an app or feature through Windows Defender Firewall.
  • Otherwise confirm the server is running, the File protocol (SFTP, SCP or FTP) matches the server, and the Port number on the Login dialog is the server’s port.
  • If your network needs a proxy, set it on the Proxy page of the Advanced Site Settings dialog.

Applies to: WinSCP for Windows (steps from the WinSCP documentation)

WinSCP shows “Network error: Connection to … refused” when the server turns your connection away, and it can also stop with a connection timed out message.

The WinSCP documentation has a help page for the refused error and a firewall answer that covers both messages.

This guide goes through those causes in the order the documentation lists them, so you can find yours quickly.

Table of Contents

Quick answer: causes and fixes

CauseWhat to do
Local firewall blocks WinSCPAdd an exception for winscp.exe in Windows Defender Firewall
Server is downAsk the server or network administrator to confirm it is running
Server has no SSH or FTP serviceConnect to a machine that runs one; Windows has neither by default
Wrong protocolMatch the File protocol on the Login dialog to the server
Non-standard portEnter the exact port in Port number
Proxy requiredSet it on the Proxy page of Advanced Site Settings

The messages this guide covers

The WinSCP error list names the refused message as “Network error: Connection to … refused” and the timeout message as “Network error: Connection to … timed out”.

For FTP, the same list adds the Windows wording “No connection could be made because the target machine actively refused it”.

The WinSCP firewall answer says the messages “Connection refused”, “Connection timed out” and “Can’t resolve hostname” can all appear when WinSCP is blocked while other clients connect.

Step 1: Allow WinSCP through the firewall

The WinSCP documentation says a local firewall with per-application rules may allow your other clients and still block WinSCP.

  1. Open Control Panel > System and Security > Windows Defender Firewall.
  2. Click Allow an app or feature through Windows Defender Firewall.
  3. Add an exception for winscp.exe.
  4. Try the connection again.

The page notes this can start right after a WinSCP update, because some firewalls check the fingerprint of the program file and an upgrade changes it.

That means an exception you added earlier may no longer count, so add it again.

Step 2: Check your antivirus

The documentation says some antivirus programs include firewall features, so check their settings too.

To test whether it is the cause, it suggests disabling the antivirus temporarily.

Turn it back on. Switch the antivirus on again as soon as the test is done, whatever the result.

Step 3: Confirm the server is running

The first cause on the WinSCP refused-error page is that the server is down.

It tells you to ask the server or network administrator to confirm that the server is running.

Step 4: Make sure the target runs SSH or FTP

WinSCP needs an SSH or FTP server on the remote machine.

The documentation says Windows does not include either by default, so connecting to another Windows workstation typically fails.

If the remote machine is a Windows 11 PC you control, our guide to turning on OpenSSH in Windows 11 covers the server side.

Step 5: Match the protocol

SFTP and SCP run over SSH, while FTP is a separate protocol, so the server must support the one you selected.

The documentation points out that WinSCP defaults to SFTP while many similar applications default to FTP.

If another program connected with FTP, change the File protocol on the Login dialog to match.

Our guide to connecting and transferring files with WinSCP lists every Login dialog field and its default port.

Step 6: Enter the right port

If the server listens on a custom port, the documentation says to enter that exact port number on the Login dialog.

ProtocolDefault port
SSH (SFTP)22
FTP21
FTPS (implicit)990

Step 7: Set a proxy if your network needs one

The refused-error page says that if your network requires a proxy, you specify it on the Proxy page of the Advanced Site Settings dialog.

The Proxy page documentation places it under Login Dialog, Advanced, Connection, Proxy.

It also says WinSCP does not try to work out on its own whether a proxy is needed, so you must set one explicitly.

Proxy typeWhat it is
NoneDefault; no proxy is used
HTTPConnects through a web server that supports the HTTP CONNECT command
SOCKS4 / SOCKS5Connects through a SOCKS server
TelnetUses a firewall Telnet-style proxy; not for FTP, WebDAV or S3
LocalRuns a local command as the proxy; not for FTP, WebDAV or S3

The Autodetect button finds proxy settings, but the page says it works for HTTP proxies only.

If you see Timeout detected instead

A separate WinSCP page covers the message “Timeout detected”, and its first advice is to set a longer timeout interval.

If it happens at login or when a transfer starts over SFTP or SCP, the page says the causes and fixes for the refused error apply here too.

With FTP, the page says a firewall, proxy or NAT device is likely blocking the data connection.

If an FTP transfer times out as a long transfer finishes, it says a faulty firewall, proxy or NAT device probably dropped the control connection, and that WinSCP cannot keep it alive during the transfer.

If WinSCP cannot resolve the hostname

Check the spelling of the server name first, because the guide notes it can differ from your website’s domain.

If the name is right and nothing resolves, fixing a DNS server that is not responding on Windows covers the usual causes.

Sources

This guide follows the WinSCP pages Network error: Connection refused, Why is WinSCP not able to connect to a server, when other clients are?, Timeout detected and The Proxy Page, read on Nov 29 2026.

Leave a Reply

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