Get your free beta license ↗
FTP, SFTP and SSH · OpenSSH

An SFTP upload fails in the top folder

Last updated 30 Nov 2026
Summary

An SFTP upload to the top folder, /, fails with Permission denied. OpenSSH requires root to own that folder, so upload to /files, where the customer's files live.

Symptoms

An upload to / fails with the following error.

Output
dest open "/x.txt": Permission denied

The same upload works in /files.

Cause

SFTP shows the customer /home/USER as /. Root owns that folder, as sshd requires.

The customer's files are in /files, where the SFTP session starts.

Resolution

  1. Upload to /files or a folder under it. The customer's sites are under /files/web.

  2. Set the remote folder in the SFTP client to /files so the client opens there.

  3. Run this command to open an SFTP session directly in /files.

    sftp USER@server.example.net:/files/