Can't Connect with WinSCP! A Complete Guide to Causes and Solutions for Beginners
WinSCP is an essential tool for website creation and server management. It's incredibly convenient for uploading and downloading files to and from a server, right? But have you ever tried to use it, only to find that "for some reason, I can't connect..."?
Even when an error message appears, it's full of technical jargon you don't understand, and it's easy to feel your mind go blank...π±
In this article, aimed at beginner web creators, we will thoroughly explain the main causes of connection failures in WinSCP and their solutions, using diagrams and specific examples. By reading this article, you'll be able to calmly and coolly resolve troubles without panicking!
First, the Basics! Double-Check Your Connection Information
"Silly mistakes" happen to everyone. Before you start thinking about complex causes, let's first check if the most basic connection information is correct. Surprisingly, this is often the cause of the problem.

Let's take another close look at this screen when you start WinSCP.
- β File protocol: Is it set according to your server contract? "SFTP" and "FTP" are completely different things. There's also an FTPS option. Double-check your server's control panel or the email you received when you signed up.
- β‘ Host name: This is the server's address. Check every single character to see if it includes `www.`, or if you've mixed up a hyphen (-) with an underscore (_). The same applies if it's an IP address (e.g., `123.45.67.89`).
- β’ Port number: This is often determined by the protocol (e.g., `22` for SFTP, `21` for FTP), but some servers may specify a special port number. This is also important to check.
- β£ User name: This is the ID for logging into the server.
- β€ Password: Since the password is displayed as `β` when you type it, it's easy to miss a typo. The surest way is to type it into a notepad first, then copy and paste it.
β Checkpoint: When you copy and paste, make sure there are no extra spaces before or after the text. This alone can cause an authentication error.
Common Error Messages, Causes, and Solutions
If you can't connect even after checking the basic information, the error message that appears will be a big hint. Here, let's look at the causes and solutions for each representative error message.
1. "Network error: Connection timed out"
This means that WinSCP tried to contact the server, but it didn't get a response within a certain amount of time.

π€ Possible Causes
- The host name or IP address is incorrect.
- The port number is incorrect.
- The server-side firewall is blocking the connection from your PC.
- Your own PC's firewall or security software is blocking WinSCP's communication.
- The server is down, or the SSH/FTP service is stopped.
π Solutions
- First, go back to the "Basics" section above and double-check the host name and port number.
- If you're using a rental server, check the control panel for settings like "IP Address Restriction" or "Overseas IP Address Restriction." If this is set and your IP address is not on the allow list, you'll need to add it.
- Try temporarily disabling your PC's security software and attempting to connect. If you can connect this way, you'll need to configure your security software to allow WinSCP's communication.
- If you've checked all of the above and it still doesn't work, there may be a problem with the server itself. Try contacting your server administrator.
2. "Host '...' does not exist"
This is a relatively straightforward error, meaning "the host name (server address) you entered could not be found."
π€ Possible Causes
- A simple typo in the host name.
- You've entered a host name that doesn't exist.
π Solutions
- Thoroughly check the host name you entered. The most reliable way is to copy and paste the information from the email sent by your server provider or from the admin panel, without changing a single character.
- If you've just acquired a domain (e.g., `example.com`), it can take some time for the DNS information to propagate across the internet (from a few hours to a maximum of 72 hours). Try again after a little while.
3. "Access denied" / "Authentication failed"
You've managed to reach the server, but you're being turned away at the door with a "Who are you? I can't let you in." It's highly likely that there's a problem with your authentication credentials (ID, password, or key).

π€ Possible Causes
- The username or password is incorrect.
- If you're using "key authentication" for an SFTP connection, the private key you've configured is wrong, or the public key isn't registered on the server.
- The password has expired.
- The user account you're trying to connect with is disabled.
π Solutions
-
Re-check your username and password:
- Case matters. `Password` and `password` are two different things.
- Check that you haven't mixed up the number `0` with the letter `O`, or the number `1` with the letter `l`.
- As mentioned before, it's a good idea to type it in a notepad and then copy and paste.
-
Checkpoints for key authentication (SFTP):
Key authentication is a method of authenticating using a pair of files called a "private key" and a "public key" instead of a password. It's recommended as a more secure connection method.
- On the WinSCP login screen, click the "Advanced..." button, then select "SSH" > "Authentication" from the left menu.
- In the "Private key file" field, check that the correct `.ppk` file is specified. `.ppk` is the private key file format used by WinSCP and PuTTY.
- You need to check that the corresponding public key is correctly installed on the server. Usually, you write the contents of the public key to a file named
/home/username/.ssh/authorized_keyson the server. If you're unsure about this process, ask your server administrator to check. - If you've set a passphrase (a password to unlock the key) for your private key, you'll be prompted to enter it. Be careful of typos, just like with a password.
4. "Server refused our key"
This is an error specific to using key authentication. It means the server is rejecting the private key that WinSCP presented, saying, "I don't know this key."
π€ Possible Causes
- The private key configured in WinSCP and the public key registered on the server are not a correct pair.
- The public key is not registered on the server at all.
- The permissions for the file where the public key is registered (`authorized_keys`) or its parent directory (`.ssh`) are incorrect.
π Solutions
If you can log in to the server via SSH, you can check the settings with the following commands. If you can't log in via SSH or are unsure about command-line operations, it's smoother to ask your server administrator, "I'm getting a key authentication error with WinSCP. Could you please check the settings and permissions for `authorized_keys`?"
[For Requesting Confirmation] Command to check permissions of authorized_keys
This command is run on the server. Sharing the result of this command with the administrator can speed up problem identification.
ls -la ~/.ssh/authorized_keys
The correct permission is `600` (-rw-------). This means only the owner can read and write. If it's set to anything else (like `644`), the server won't read the key for security reasons.
[For Requesting Confirmation] Command to check permissions of the .ssh directory
ls -ld ~/.ssh
The permission for the `.ssh` directory itself needs to be `700` (drwx------). You can use the following commands to reset them, but if you're not confident in your skills, always ask your administrator to do it.
[For Changing Settings] Permission change commands (for advanced users)
chmod 700 ~/.ssh
chmod 600 ~/.ssh/authorized_keys
Still Can't Solve It? The Last Resort: The "Logging" Feature
If you've tried all the methods introduced so far and still can't connect, WinSCP's "Logging" feature is your last hope.
When you enable logging, WinSCP records in detail what kind of communication it attempted with the server and at what stage it failed. Looking at this log file can provide experts and server administrators with very powerful clues to identify the cause.
- Click the "Advanced..." button on the login screen.
- Check the "Advanced options" box at the bottom left of the window that opens.
- An item called "Logging" will appear in the left-hand menu; click it.
- In the "Log file" field, enter the destination and file name for the log output (e.g., `C:\Users\YourUser\Desktop\winscp.log`). It's easy to choose a location using the "..." button.
- Set the "Log level" to "Normal" or "Debug 2" to get more detailed information.
- Try to log in once with this setting. If it fails, a log file will be generated in the location you specified.

The contents of the log file are technical, but if you look closely around the error message, you should find keywords you've seen before, like "Access denied" or "Connection failed". Providing this log file to your server administrator will speed up the problem-solving process considerably.
Summary
It's really frustrating when you can't connect with WinSCP and your work comes to a halt. However, most of the causes are due to basic configuration mistakes or environmental differences like the ones introduced here.
If you encounter trouble, first refer to this article and calmly check the following steps:
- Re-check basic information: Host name, protocol, port number, user name, password.
- Check the error message: Is it a timeout, host not found, or authentication failure?
- Check key authentication (for SFTP): Is the private/public key pair correct? Are the permissions correct?
- Get the logs: If you really can't solve it, get a detailed log and consult an expert or administrator.
If you check each one carefully, you'll definitely find a clue to the solution. Good luck! π