
Maybe you need to work on remote projects, maybe you have multiple computers running different operating systems and you find yourself always going back and forth between them, or maybe you just need to access a server. So how would you go about it?
You could use a cloud file hosting service and sync everything across your computers, but depending on your needs that can get expensive. You could use a USB stick or external HDD/SSD, but if you run different operating systems with different filesystems that can quickly become an unnecessary headache. You can also use an SFTP client like FileZilla, but for a mounted directory that you can browse from your usual file manager, take a look at SSHFS.
SSHFS is a filesystem client that uses the SSH File Transfer Protocol (SFTP) to mount a remote directory on your local machine.
Updated: November 2026. The original screenshots date from 2020. Follow the updated commands in the text, not the historical screenshots.
Important: SSHFS 3.7.6 fixes two serious security vulnerabilities, CVE-2026-47187 and CVE-2026-48711. Use an updated release or a distribution package that contains both fixes. SSHFS 3.7.7 also includes subsequent fixes. Check the macOS and Windows sections before installing anything, as their packaged versions may lag behind upstream.
ALSO READ: How to mount a torrent file as a read-only directory on Linux and macOS.
What you need before using SSHFS
There are two machines involved. The local machine (client) is where you want the files to appear. The remote machine (server) is where the files actually live. Install SSHFS on the client and make sure the server provides SSH with SFTP enabled. You do not need to enable an SSH server on your client, or install SSHFS on the remote machine.
You’ll also need the remote username, hostname or IP address, SSH port (normally TCP 22), and permission to access the remote directory. In the examples below, replace alice, 192.0.2.10 (an example address, not a real server) and projects with your own values. Keep the SSH port restricted to the networks and clients that need it. Don’t forward port 22 from your router just to access a computer on your local network.
Enable SSH on a Linux server
Run the commands for your distribution on the remote machine only, if it doesn’t already offer SSH and SFTP. The examples assume systemd.
Arch Linux:
sudo pacman -S openssh
sudo systemctl enable --now sshd.service
Debian and Ubuntu:
sudo apt update
sudo apt install openssh-server
sudo systemctl enable --now ssh.service
Some Ubuntu installations use socket activation (ssh.socket); if SSH is already working, leave the existing activation method alone.
Fedora, CentOS Stream and RHEL:
sudo dnf install openssh-server
sudo systemctl enable --now sshd.service
The enable --now option starts the service and configures it to start automatically. If you only need it for a temporary session, use systemctl start instead. Check that the server’s firewall allows the intended client to connect to its SSH port.
Enable Remote Login on a Mac server
On the Mac that holds your files, go to System Settings > General > Sharing, turn on Remote Login and use its information button to choose which users can connect. Select only the accounts that need access. Leave full disk access for remote users disabled unless you specifically need it.
Apple’s Remote Login guide explains the current settings. Older macOS versions used System Preferences > Sharing. The Mac displays the SSH login details in the Remote Login panel.
Enable SSH on a Windows server
If your remote machine runs Windows, use Microsoft’s OpenSSH Server setup guide for your Windows version. On supported Windows installations you can install OpenSSH Server from Optional Features or use an administrator PowerShell:
Add-WindowsCapability -Online -Name OpenSSH.Server~~~~0.0.1.0
Start-Service sshd
Set-Service -Name sshd -StartupType Automatic
If the server component is already installed, skip the installation command. Check the firewall rule and restrict it to trusted networks as appropriate. Windows SFTP paths depend on the server configuration, so check them with SFTP rather than assuming a Linux directory layout.
Test the connection first
Find the remote machine’s IP address in its network settings or router. On Linux you can also run ip addr, and on Windows use ipconfig. A successful ping doesn’t tell you whether SSH or SFTP is working. From the client, use the OpenSSH client (on Windows this is a separate optional component if it isn’t installed already):
ssh alice@192.0.2.10
exit
sftp alice@192.0.2.10
The exit command closes the SSH shell after login. In SFTP, run pwd and ls to check the starting directory, then bye to disconnect. If your server only permits SFTP, skip the interactive SSH shell test.
On the first connection, verify the server’s host key fingerprint with its administrator or directly on the server before accepting it. An SSH key warning is not something to click through. For example, on a Linux server using an Ed25519 host key, its administrator can display the fingerprint with:
ssh-keygen -lf /etc/ssh/ssh_host_ed25519_key.pub
Compare the same key type and fingerprint shown by the client. If it changes unexpectedly, stop and investigate before updating your trusted host keys.
How to mount a remote filesystem on Linux
1. Install SSHFS
On your local machine, install SSHFS and the SSH client. Update your distribution packages so you get the available security fixes.
- Arch Linux:
sudo pacman -S sshfs openssh - Debian/Ubuntu:
sudo apt update, thensudo apt install sshfs openssh-client(on Ubuntu the SSHFS package is in Universe). - Fedora:
sudo dnf install fuse-sshfs openssh-clients - CentOS Stream/RHEL:
sudo dnf install fuse-sshfs openssh-clientsafter enabling the appropriate EPEL repository for your supported release. Availability varies by release; check the package listing.
Check the installed version with sshfs --version. Some distributions backport security fixes without changing to the newest upstream version, so check their security notices as well.
2. Create a mount point
Where do you want the remote files to appear? You can create an empty directory in your home folder without using sudo:
mkdir -p "$HOME/remote-projects"
Or use /mnt, as in my original example (since I was mounting my macOS filesystem on my Linux machine, I creatively named the folder “mac”):
sudo mkdir -p /mnt/mac
sudo chown "$(id -u):$(id -g)" /mnt/mac
This changes the ownership of the local, unmounted directory to your current user and primary group, not the files on the server. Make sure the directory is empty and isn’t already a mount point. Don’t use recursive ownership changes on a mounted filesystem.
These original Linux screenshots use my own directory names and account details. Use the commands above with your own values.


3. Mount the remote directory
Run SSHFS as your regular user, not as root:
sshfs alice@192.0.2.10:projects "$HOME/remote-projects"
Here, projects is relative to the remote user’s home directory (or the SFTP starting directory). Use alice@192.0.2.10: for the starting directory itself, or an absolute path such as alice@192.0.2.10:/srv/projects if the server permits it. To mount at /mnt/mac, replace the local path with that directory.
If SSH uses a different port, for example 2222:
sshfs -p 2222 alice@192.0.2.10:projects "$HOME/remote-projects"

Now when you cd into the mount point or open it in your file manager, you’ll see the remote files:
ls -la "$HOME/remote-projects"

Changes you make to mounted files can modify the originals on the server. SSHFS is not a backup or an offline synchronization tool. If you only need to read files on Linux, you can add -o ro to the mount command.
4. Unmount the remote filesystem
Close any files or applications using the mount and leave the directory before unmounting it.
cd "$HOME"
fusermount3 -u "$HOME/remote-projects"
For an older FUSE 2 installation, use fusermount -u "$HOME/remote-projects" instead. The original screenshot below shows that older command.

How to mount a remote filesystem on macOS
1. Install macFUSE and SSHFS
The old brew install sshfs and brew cask install osxfuse instructions are obsolete on macOS. The macFUSE website provides installers for macFUSE and SSHFS, for Apple Silicon and Intel Macs. macFUSE 5.5.0 lists macOS 12 and later and includes work for macOS 27. The Homebrew casks are macfuse and sshfs-mac, not the Linux SSHFS formula. If you’re unfamiliar with the package manager, here’s my Homebrew starter guide.
Before installing: At the time of this update the macFUSE download page and Homebrew’s SSHFS cask listing still list SSHFS 3.7.5, which predates the two security fixes mentioned above. Check for a signed macOS installer containing SSHFS 3.7.6 or newer (or documented backported fixes). Until such a build is available, I would hold off on installing SSHFS through either route. Updating macFUSE alone does not update SSHFS.
Once a fixed package is available, install macFUSE first, then the SSHFS package, following the installer instructions. The corresponding Homebrew installation command is shown here for reference; check the cask version before running it:
brew info --cask sshfs-mac
brew install --cask macfuse sshfs-mac
sshfs --version
There is another option if you already use MacPorts. Its package index lists a newer SSHFS version, including 3.7.7 in the current search listing. With MacPorts installed for your macOS release, check the version before installing:
sudo port selfupdate
port info sshfs
If the version is 3.7.7 or newer, install it and its dependencies:
sudo port install sshfs
/opt/local/bin/sshfs --version
The last command assumes the default MacPorts installation location. I haven’t verified a successful MacPorts build or mount on macOS 27.2.1. SSHFS 3.7.7 also includes macOS mounting fixes, and the macFUSE project has an open issue about SSHFS mount failures on macOS 27.2. Don’t assume that a successful installation means the mount will work.
2. Choose the macFUSE backend
macFUSE 5 has two ways to mount filesystems. On supported versions of macOS, including macOS 26 and 27, the FSKit backend runs in user space and doesn’t require reducing startup security. If prompted, enable the relevant macFUSE file system extension in System Settings > General > Login Items & Extensions > File System Extensions.
The traditional kernel backend may require approving the macFUSE kernel extension in Privacy & Security and restarting. On Apple Silicon, using this backend for the first time also requires Recovery Mode, Reduced Security and permission for identified developers’ kernel extensions. This is a change to your Mac’s security policy, so don’t do it just because an old tutorial tells you to. See the macFUSE setup instructions and backend limitations.
3. Mount and unmount the remote directory
The following is the documented FSKit mount syntax, not a confirmed test on macOS 27.2.1. Use an updated SSHFS build that works with macFUSE and FSKit, preferably 3.7.7 or later. Use a new empty mount point under /Volumes:
sudo mkdir /Volumes/RemoteProjects
sudo chown "$(id -u):$(id -g)" /Volumes/RemoteProjects
sshfs -o backend=fskit alice@192.0.2.10:projects /Volumes/RemoteProjects
If the directory already exists, choose another unused name. Run the SSHFS command without sudo. If using the traditional kernel backend and you have already approved it, a folder in your home directory is another option:
mkdir -p "$HOME/remote-projects"
sshfs alice@192.0.2.10:projects "$HOME/remote-projects"
These original screenshots from 2020 show the older kernel based workflow, not FSKit or a current macOS test.


Once mounted, you can browse the remote directory in Finder or Terminal. Close any open files, leave the directory and unmount it with:
cd "$HOME"
umount /Volumes/RemoteProjects
Use umount "$HOME/remote-projects" instead if that’s where you mounted it.

There’s no need to enable Remote Login on your Mac unless it is also acting as the remote server.
How SSHFS works on Windows
The original Windows method uses WinFsp and SSHFS-Win to map an SFTP directory as a network drive. The project documents this workflow, but the available SSHFS-Win releases are old and I could not establish that they include the upstream 2026 security fixes. More importantly, the standard network drive wrapper disables strict SSH host key checking and discards the usual known-hosts file. That means you cannot rely on it to authenticate the server as ordinary OpenSSH does.
I would not install an unpatched build or use a mapping method that does not verify the server, even on a local network. For now, a current SFTP client with host key verification is a better choice for Windows if you only need to transfer files. The instructions below document the original mapping workflow for reference, not a recommendation to bypass these security limitations.
1. Install the Windows components
The current project download locations are WinFsp and SSHFS-Win releases. The latter depends on WinFsp. Check that the SSHFS-Win build is maintained, patched and compatible with your Windows version and processor before installing. Do not assume native ARM64 support from the x64 and x86 installers. Microsoft’s OpenSSH Server is not required on a Windows client just to mount a remote directory.
2. Map a remote directory
The following Windows screenshots are historical examples from 2020, not evidence of a secure or supported current installation.
In Windows 11, File Explorer > This PC > the three-dot menu > Map network drive is the usual route. Older versions also offer it from the context menu. Choose an unused drive letter. The SSHFS-Win documentation defines these paths:
\\sshfs\alice@192.0.2.10
\\sshfs\alice@192.0.2.10\projects
\\sshfs.r\alice@192.0.2.10\srv\projects
\\sshfs\alice@192.0.2.10!2222\projects
The first path maps the remote user’s home directory, the second maps a folder beneath it, the third starts from the remote SFTP root rather than the home directory, and the last uses port 2222. Mapping the root does not give you root privileges.

For password authentication, Windows may ask for the remote account’s credentials. Do not enter your password if the server’s identity cannot be authenticated by your chosen client.

A successful mapping appears as a drive in File Explorer. To disconnect it, use Disconnect network drive, or run net use Z: /delete in Command Prompt (replace Z: with the mapped letter). Reconnect at sign-in remembers a mapping but cannot guarantee connectivity or authentication at every login.

SSHFS-Win also documents \\sshfs.k\ for key authentication relative to the home directory and \\sshfs.kr\ relative to the root. Its standard mapping method uses %USERPROFILE%/.ssh/id_rsa by default and supports only keys without a passphrase; a host alias in the SSH configuration can select a different key. I would not remove a key’s passphrase or reuse a sensitive private key just to make this legacy method work.
SSH keys and persistent mounting
If you frequently access the same remote directory from Linux or macOS, SSH keys can save you from typing the remote account’s password every time. Create a separate key on the client (choose a new filename if it already exists):
ssh-keygen -t ed25519 -f "$HOME/.ssh/id_ed25519_sshfs"
ssh-copy-id -i "$HOME/.ssh/id_ed25519_sshfs.pub" alice@192.0.2.10
The second command requires ssh-copy-id and an account that permits key installation over SSH. Alternatively have the server administrator add your public key to the account’s authorized keys file. Never copy the private key to the server. Use a passphrase and, where available, your SSH agent:
ssh-add "$HOME/.ssh/id_ed25519_sshfs"
ssh -i "$HOME/.ssh/id_ed25519_sshfs" alice@192.0.2.10
After closing the SSH session, mount the directory with:
sshfs -o IdentityFile="$HOME/.ssh/id_ed25519_sshfs",IdentitiesOnly=yes,StrictHostKeyChecking=yes,reconnect,ServerAliveInterval=15,ServerAliveCountMax=3 alice@192.0.2.10:projects "$HOME/remote-projects"
This is the Linux example. On macOS use your chosen mount point and backend option. The strict host key setting assumes you’ve already verified and recorded the server key. Reconnect and keepalive options help after interruptions, but open files or writes can still fail. Save your work before disconnecting.
Keep a mount configuration across reboots on Linux
You can add an entry to /etc/fstab. For a regular user’s mount, first create and own the empty mount point and test the manual SSHFS connection. Example for a local user named sam with home directory /home/sam (replace all example values):
alice@192.0.2.10:/srv/projects /home/sam/remote-projects fuse.sshfs noauto,user,_netdev,IdentityFile=/home/sam/.ssh/id_ed25519_sshfs,IdentitiesOnly=yes,UserKnownHostsFile=/home/sam/.ssh/known_hosts,StrictHostKeyChecking=yes,reconnect,ServerAliveInterval=15,ServerAliveCountMax=3 0 0
Back up /etc/fstab before editing it. The noauto option avoids trying to mount before the network or your SSH credentials are ready. user permits a regular user to request the mount; _netdev identifies it as a network filesystem. The entry survives a reboot, but the actual mount does not. After signing in and unlocking your key, run:
mount "$HOME/remote-projects"
Use fusermount3 -u "$HOME/remote-projects" to unmount. Some distribution mount helpers may handle the user option differently; if the mount fails, use the direct SSHFS command rather than mounting as root. See the SSHFS manual and mount manual.
For an automatic mount at login, run the tested SSHFS command from your desktop’s startup application facility, under your own user account, after the network and SSH agent are ready. Do not expect a passphrase prompt or your desktop SSH agent to work during system boot. Unattended boot mounts need a separate, deliberately configured service identity, host verification and network ordering. For ordinary desktop use an alias is often simpler.
SSHFS troubleshooting
- Connection refused or timed out: Check the host, port, SSH service on the server and firewall rules. Run
sftp -v alice@192.0.2.10first (use-P 2222for a custom port). - Permission denied at login: Check the remote username, allowed authentication methods, key and server account permissions. Use
ssh -v alice@192.0.2.10to see which identity is attempted, if shell access is allowed. - Host identification has changed: Stop. Confirm whether the server’s key was legitimately replaced before editing your known hosts. Never disable host verification just to make a mount work.
- Permission denied after mounting: Check the remote account’s permissions and the local mount point’s ownership. Changing local ownership does not grant remote access. Don’t use
chmod 777,allow_otheror root as a blanket fix. - Remote directory not found: Use SFTP’s
pwdandlsto confirm the actual path, especially for restricted SFTP accounts and Windows servers. - Transport endpoint not connected or device busy: Close files and file managers, leave the mount directory, unmount with the appropriate command and reconnect. Avoid forced unmounts while writes are in progress.
- macFUSE extension not found: Check that the appropriate file system extension is enabled for the current user and that your installed versions support your macOS release. Consult the macFUSE troubleshooting guide rather than disabling system protections.
Learn more about SSHFS and SSHFS-Win. On Linux and macOS, also don’t forget to run man sshfs or sshfs -h for the options supported by your installed version.

