How to Share Files Between Windows and Kali Linux
Sharing files between Windows and Kali Linux is simple once you know the different methods available. Whether you want to copy files from Windows to access Kali Linux or share Kali Linux files with Windows, this guide covers several easy approaches. Follow along to enable file transfers between these operating systems.
Set Up Samba File Sharing
One of the simplest ways to share files between Windows and Kali Linux is using Samba. Samba allows you to set up file sharing between Linux and Windows operating systems.
Here are the steps to set up Samba sharing:
Install Samba on your Kali Linux machine if it is not already installed. Open the terminal and type:
sudo apt install samba
Create a directory you want to share, like
/home/kali/shared
. Adjust permissions so anyone can read/write here.Edit the Samba config file (
/etc/samba/smb.conf
) and add a section like:[Shared] comment = Kali Shared Folder path = /home/kali/shared browseable = yes read only = no
Restart the Samba service:
sudo service smbd restart
Once configured, you can access the shared folder from Windows by going to "Network" and connecting with the Linux IP address. Authenticate with your Kali Linux username and password.
Transfer Files With SSHFS
Another option is using SSHFS to mount your Kali Linux folders directly in Windows. This uses SSH protocol to enable file transfers.
To set up SSHFS:
Download and install SSHFS-Win on your Windows machine.
On Kali Linux, install sshfs:
sudo apt install sshfs
Create a folder on Windows you want to mount the Linux drive, like
C:\kali
.Mount the Kali folder with SSHFS-Win using a command like:
sshfs username@192.168.1.10:/home/kali /c/kali
Now you can directly copy files between the /c/kali/
folder in Windows and /home/kali/
folder in Linux.
Transfer With Web Browser
A quick way to transfer a few files is by using your web browser:
On Kali Linux, install a simple web server like Webfs.
Launch webfs pointed at your share folder:
webfsd /home/kali/shared &
Open the Windows browser and navigate to your Kali IP at port 8000 (e.g.
192.168.1.10:8000
)Drag and drop files between your Windows Downloads folder and the Kali Share folder shown in your browser.
When done, press CTRL+C in the Kali terminal to stop webfsd.
Additional Options
There are a few other ways to share files between Windows and Kali Linux as well:
File transfer tools like WinSCP that use SFTP/SCP protocol
Transfer files over a network shared drive or external drive formatted for both OSes
Sync folders with cloud storage like Dropbox or Google Drive
Conclusion
No matter which option you choose, transferring files between these operating systems is straightforward. Just pick the file-sharing method that suits your needs and preferences best. Let me know if you have any other questions!
Subscribe to my newsletter
Read articles from Pratik M directly inside your inbox. Subscribe to the newsletter, and don't miss out.
Written by
Pratik M
Pratik M
As an experienced Linux user and no-code app developer, I enjoy using the latest tools to create efficient and innovative small apps. Although coding is my hobby, I still love using AI tools and no-code platforms.