WinSCP is a free SFTP, SCP and FTP client for Windows. Apart from other functions, WinSCP can be used to present, copy and mange files and folders on a Raspberry Pi from a remote device.
WinSCP can use SCP (secure copy protocol) to log into a Raspberry Pi using its username and password. Raspbian, OpenELEC and RetroPi are among the systems that can be connected to. As a client, WinSCP has two file panels – one for the local interface and one for the remote interface. Each file panel looks similar to Windows Explorer in that it presents files and directories in a folder-like fashion.
The file panels allows for drag-and-drop functionality between the interfaces and simplifies creating, copying, renaming and moving of files and directories. User permissions can also be set using WinSCP.
Raspberry Pis are popular to use as small, standalone devices on a network. By using WinSCP, the need for these devices to have a keyboard, mouse and screen is reduced to only their setup phases. After an IP address has been obtained, WinSCP can be used from a remote computer to have file access.
WinSCP used in together with PuTTY will extend access to a windowed, terminal-like CLI.
Requirements & assumptions
- Both the Raspberry Pi and the remote computer needs to be connected on the same local network.
- The Raspberry Pi to be connected to has SSH enabled. Some Raspbian distributions has SSH enabled by default, but can be configured using the Raspi-config tool.
- The IP address of the Raspberry Pi is available. The following command can be used in the terminal to obtain the latest IP address:
Using an Ethernet cable will need no configuration and will allow network connection with an automatic assigned dynamic IP address. Using Wi-Fi will also assign a dynamic IP, but will need the network name (SSID) and the password (also called the passphrase or pre-shared key) of the wireless network. Also read 3 ways to connect a Raspberry Pi 3 to a network using Wi-Fi.
Although a static IP address for the Raspberry Pi is not required, it is recommended. A static IP will standarise the address used to access the Raspberry Pi. Read more about setting up a static IP.
Download & configure WinSCP
WinSCP can be downloaded here. The first time WinSCP is opened there will be a blank Login area (left). After clicking on New Site, supply all the details of the Raspberry Pi in the Session area. The IP address of the Raspberry Pi is saved under Host name, the File protocol should be set to SCP and the Port number should be left as 22. After selecting Save, WinSCP will prompt for a Site name and the option to save the password.
By double clicking on the Site name on the Login area, WinSCP terminal will open. After the first time the security key will be created upon acceptance.
For Raspbian, the default username and password is pi and raspberry. Multiple saved Logins to different devices can be created.
The settings can be changed by selecting the applicable saved Login and Edit. After changing the settings it needs to be saved again.
The default WinSCP settings will work for most users, but over time some additional settings might become handy. These settings can all be accessed from the Preferences situated under Tools on the main screen:
- Show hidden files -> Panels -> Show hidden files
Opening multiple instances of WinSCP is also possible. While WinSCP is already running with another session, hold down the Shift key while opening WinSCP again (i.e. by clicking on the shortcut icon).
WinSCP for OpenELEC & XBMC (Kodi)
WinSCP can be used to gain access to screenshots, fan art, banners, posters or any other media related files from Kodi.
For SCP, SSH needs to be enabled. Kodi might not have SSH enabled. SSH can be enabled from the Services section by going to Settings -> OpenELEC -> Settings (do not change the username and password settings for now). A reboot might be required. SFTP can also be used.
The default username and password for OpenELEC is root and openelec and root without a password for XBMC.
WinSCP for RetroPie
You can use WinSCP to get access to screenshots and probably many other relevant directories in RetroPie. This process is tested in RetroPie 4.2.
To use WinSCP to connect to RetroPie, SSH needs to be enabled from the RetroPie Configuration screen by choosing RASPI-CONFIG-> 5 Interfacing Options -> P2 SSH.
The default username and password for RetroPie is pi and raspberry.