Can't connect to sever with FileZilla using root.

May 19, 2017 14k views
DigitalOcean Debian

I took down my old server to revamp everything together, when I am not able to connect to FileZilla using the droplet ip/password. I already went through the process of changing the password and I am getting the message "Authentication failed.
Error: Critical error: Could not connect to server".

4 Answers


That specific error means that the username or password is incorrect. In such a case, you're trying to login as root, so the username isn't incorrect, which means the password is the issue.

Have you tried to login to the CLI using SSH with root and the password you feel is correct? If so, are you being denied there as well, or are you able to successfully login?

If you're able to login to the CLI using SSH, have you made sure that when connecting using FileZilla that you're specifying SFTP (instead of FTP) and that you're using port 22 to connect?

  • I am able to login using putty, server ip and password perfectly fine. But when I try to do so on FileZilla, using port 22. It gives me that error.

    • @rapidfx

      Are you for sure selecting SFTP instead of FTP from the drop down menu? By default, there's no FTP software installed on your Droplet unless you install it on your own, so the only option would be SFTP.

      • What do you mean? Dropdown on FileZilla or Putty. Before I never got this error and always do the same setup process.

        • Maybe issue with how you configured sftp. Have you tried MobaXterm?

          • I just made a test droplet, only thing I did was change the UNIX password, tried logging into it using FileZilla and gave me the same error message.


With FileZilla, you have two connection options -- FTP or SFTP. This is a selectable option under the Host and Port and is labeled Servertype.

You need to make sure that drop down has SFTP selected instead of FTP. Unless you install FTP software on the Droplet, you won't be able to connect using FTP, you have to connect using SFTP (which is actually more secure and better than using FTP).

You can see the dropdown in the screenshot below:

Where it says "FTP - File Transfer Protocol", you need to click that drop down and make sure SFTP is selected :-).

  • Still gives me the error.

    • @rapidfx

      Would you be able to take a screenshot of what your configuration looks like? The same panel as shown in that screenshot is what I'd like to take a look at (you can leave the host blank if you'd like so you don't expose your IP).

      If you're able to login to SSH, you should be able to login via SFTP without any issues, so either there's a configuration error or the issue is with FileZilla (as in the software).

      If you weren't able to login via SSH and SFTP, I'd say there's something wrong with the server configuration or you've been blocked by the firewall, but if you can login to one but not the other (when they use the same protocol), something seems off :-).

  • Almost 1 week I tried to access my FTP using Webuzo..
    I got similar problem like @rapidfx
    And I try to apply your answer..

    And.. It's work like a charm.. !
    Thanks @jtittle1

I found the solution

FileZilla > File > Site Manager
Add new site

Host: your public ip address
Port: 22
Protocol: SFTP - SSH File Transfer Protocol

Logon Type: Key File
User root
Key file: /path/to/your/private/key/file

Have another answer? Share your knowledge.