SFTPGo is an open-source file server that speaks SFTP (and optionally FTP/S and WebDAV), with a web admin panel and a web client for users. Unlike plain OpenSSH SFTP, users are virtual — they don’t get Linux accounts or shell access — and each can have its own folder, quota, permissions and even storage backend (local disk, S3-compatible object storage, Google Cloud Storage, Azure Blob).
Typical uses: exchanging files with clients and partners, receiving uploads from devices or scanners, giving a team a private Dropbox-like space, and putting an SFTP front end on object storage.
1. Run SFTPGo with Docker
mkdir -p /srv/sftpgo/{data,config}
chown -R 1000:1000 /srv/sftpgo
docker run -d --name sftpgo --restart unless-stopped \
-p 2022:2022 \
-p 127.0.0.1:8080:8080 \
-v /srv/sftpgo/data:/srv/sftpgo \
-v /srv/sftpgo/config:/var/lib/sftpgo \
drakkan/sftpgo:latest
- 2022/tcp — SFTP, exposed publicly.
- 8080/tcp — web admin and web client, kept on localhost (we’ll put Nginx in front).
Open the firewall for SFTP: ufw allow 2022/tcp. (OpenSSH stays on port 22 for your own administration.)
2. HTTPS for the web interface
Proxy files.example.com to 127.0.0.1:8080 with Nginx and add a Let’s Encrypt certificate — see Nginx reverse proxy for Docker containers. Then open:
https://files.example.com/web/admin— create the first admin account on first visit.https://files.example.com/web/client— the user web client.
Enable two-factor authentication for admins in the admin’s profile.
3. Create users
In Users → Add:
- Username and password and/or public SSH keys (recommended for automation).
- Home directory — created automatically under the data folder.
- Quota — size and/or number of files.
- Permissions — per directory: list, download, upload, overwrite, delete, rename, create dirs…
- Allowed IPs/networks — restrict partners to their office IPs.
- Bandwidth limits and max sessions if needed.
Test from your computer:
sftp -P 2022 [email protected]
Any SFTP client (FileZilla, WinSCP, Cyberduck, rclone) works.
4. Share links and the web client
Users can upload and download in the browser and create share links (optionally password-protected, with expiry and download limits) — handy for sending large files to people without accounts.
5. Optional: WebDAV
WebDAV lets users mount their folder as a network drive in Windows, macOS or Linux. Enable it by adding a binding with environment variables, for example:
-e SFTPGO_WEBDAVD__BINDINGS__0__PORT=10080
and proxy it through Nginx with HTTPS. Never expose WebDAV over plain HTTP.
6. Store files in object storage
Per user (or per virtual folder), choose S3 as the filesystem and enter bucket, region, endpoint and keys. SFTPGo then streams uploads straight to the bucket — useful for large archives or when the VPS disk is small. You can even use your own S3 service, such as Garage.
7. Event rules and automation
SFTPGo’s event manager can run actions on upload/download/delete: send an email or webhook, run a command, move or compress files, or notify on quota limits. Example: when a partner uploads a file, call your application’s webhook to process it.
8. Harden and back up
- Keep the admin interface behind HTTPS, with 2FA; consider allowing admin access only from your IP.
- Enable SFTPGo’s built-in defender (brute-force protection) in the configuration.
- Back up
/srv/sftpgo/config(users and settings database) and the data folder — see automated VPS backups. - Update the container regularly:
docker pull drakkan/sftpgo:latestand recreate.
Sizing
SFTPGo itself is light; storage is the main requirement. A Storage VPS with a large SSD makes an affordable file server. Related: encrypting VPS traffic.