If you try to connect to a SFTP server using FileZilla, you may see a Critical error: Could not connect to server. Here’s why you see this error and how to fix it.
When I entered the hostname and password and tried to connect to the FTP server, it gave me the following error:
Error: Cannot establish FTP connection to an SFTP server. Please select proper protocol.
Error: Critical error: Could not connect to server
Fixing ‘Critical error: Could not connect to server’ in Linux
By reading the error message itself made me realize my mistake. I was trying to establish an FTP connection with an SFTP server. You see, I had SFTP setup on the Linux server. Clearly, I was not using the correct protocol which should have been SFTP and not FTP.
As you can see in the picture above, FileZilla defaults to FTP protocol.
Solution for “Cannot establish FTP connection to an SFTP server”
Solution is simple. Use SFTP protocol instead of FTP. The one problem you might face is to know how to change the protocol to SFTP. This is where I am going to help you.
In FileZilla menu, go to File->Site Manager.
In the Site Manager, go in General tab and select SFTP in Protocol. Also fill in the host server, port number, user password etc.
I hope you can handle things from here onward.
I hope this quick tutorial helped you to fix “Cannot establish FTP connection to an SFTP server. Please select proper protocol.” problem. If you have questions or suggestion, do let me know. If this article helped you fix the problem, I won’t mind a simple ‘thanks’ comment :)
In related articles, you can read this post to know how to set up FTP server in Linux.