SFTP on Android — Securely Connect to SSH Servers with AnExplorer

SFTP on Android — Securely Connect to SSH Servers with AnExplorer

Last Updated :

SFTP on Android with AnExplorer

SFTP (SSH File Transfer Protocol) is the secure way to transfer files over the internet. Unlike plain FTP, every SFTP connection is encrypted via SSH — your credentials and file data are protected in transit. AnExplorer supports SFTP with both password and SSH key authentication.

SFTP is the right choice when:

  • Connecting to a remote server (VPS, cloud server, home server with port-forwarding)
  • Accessing a Synology or QNAP NAS from outside your home network
  • Working with a Linux machine or Raspberry Pi over the internet
  • Security is important (e.g., you're on public Wi-Fi)

For local-only transfers on a home network, SMB or FTP are simpler options.


Step-by-Step: Add an SFTP Connection

  1. Open AnExplorer
  2. Tap + in the sidebar > SFTP
  3. Enter:
    • Host: IP address or domain (e.g., 203.0.113.50 or myserver.example.com)
    • Port: Default SSH port is 22; some providers use 2222 or a random high port
    • Username: Your SSH login username (e.g., ubuntu, pi, admin)
    • Password: Your SSH password, OR leave blank if using an SSH key
    • SSH Key: (Optional) Tap to import a private key file (.pem, id_rsa)
  4. Tap Connect
  5. If prompted to accept the server's fingerprint (host key), verify it matches and confirm
  6. Bookmark the connection for quick access

Password vs SSH Key Authentication

MethodSecurityConvenience
Password🟡 OKEasy to set up
SSH Private Key✅ Much strongerRequires key setup

Using SSH Key Auth

If your server uses key-based authentication (common on AWS, DigitalOcean, Linode, etc.):

  1. Copy the .pem or private key file to your phone storage
  2. In AnExplorer SFTP setup, tap Private Key and navigate to your key file
  3. Leave the password field blank (or enter passphrase if your key is passphrase-protected)
  4. Connect — SFTP authenticates via your key without a password

Common SFTP Use Cases

VPS / Cloud Server (AWS, DigitalOcean, Linode, Vultr)

All major VPS providers use SSH + key-based auth:

  • Host: Your VPS IP (e.g., 203.0.113.50)
  • Port: 22
  • Username: ubuntu (Ubuntu/Debian), ec2-user (Amazon Linux), root (depends on provider)
  • Key: The .pem file downloaded when you created the instance

Once connected, you can browse /var/www/html to manage web files, /home/username/ for user files, or any directory your SSH user has access to.

Synology NAS (Remote SFTP)

  1. DSM > Control Panel > Terminal & SNMP > Enable SSH service
  2. Port: 22 (or change for security)
  3. Connect from AnExplorer: NAS public IP or DDNS hostname, port 22, DSM username/password
  4. At home on local Wi-Fi, SMB is faster. SFTP is better when you're away from home.

Raspberry Pi

  1. Enable SSH on Pi: sudo systemctl enable ssh && sudo systemctl start ssh
  2. Find Pi IP: hostname -I
  3. Connect from AnExplorer: Pi's local IP, port 22, username pi (Raspberry Pi OS default)
  4. Browse /home/pi/ for user files, /media/pi/ for attached USB drives

Linux Home Server

Any Linux machine with OpenSSH server installed is immediately accessible:

  • Install: sudo apt install openssh-server (Ubuntu/Debian)
  • Start: sudo systemctl enable --now ssh
  • Connect from AnExplorer using the machine's IP and your Linux username

SFTP vs FTP vs SFTP

ProtocolPortEncryptionBest for
FTP21Local network only
FTPS990✅ TLSFTP servers with TLS support
SFTP22✅ SSHAny SSH-capable server

SFTP and FTPS are both encrypted, but SFTP runs over SSH (port 22) which is already open on most servers. FTPS requires TLS certificate setup on the server side. SFTP is easier to configure and more universally supported.


Troubleshooting SFTP

"Authentication failed" with correct password:

  • The server may have PasswordAuthentication no in /etc/ssh/sshd_config — key auth required
  • Check username case (case-sensitive on Linux)
  • On AWS/GCP, root password login is typically disabled; use the correct user (ubuntu, ec2-user, etc.)

"Connection timeout" (never connects):

  • Firewall on the server may be blocking port 22 — check server security group / iptables rules
  • Some home routers don't forward port 22 to your server — check port-forwarding rules

"Host key verification failed":

  • This happens if the server's SSH fingerprint changed (e.g., server was rebuilt)
  • Remove the old known host entry in AnExplorer's SFTP settings and reconnect

Transfer is slow over mobile data:

  • SFTP over 4G/LTE is typically 5–15 MB/s. Check your mobile data speed with a speed test first.
  • Large transfers are faster on Wi-Fi to a home VPN + SMB, but that requires VPN setup.

Install

Install AnExplorer

Copyright © DWorkS 2011 – 2026 All rights reserved