Using Chrome Remote Desktop, can I transfer files between computers?
Is there a way to transfer files between remotely connected computers with the Google Chrome Remote Desktop plugin?
If not, is there a simple way I can transfer files between connected computers?
Solution 1:
I don't believe my answer is accurate any more.
See https://superuser.com/a/1453775/146314
Original Post
This can't be done. As a work around, you could always email it to yourself though, or use Google Drive / drop box or similar.
Details about Chrome RDP
Solution 2:
This is kind of a joke answer but since copy and paste is supported between the target and the host, the geeky way to copy a file without resorting to intermediate cloud storage would be to:
- On the source: use any available encoder to convert the file to Base64/UUEncode so you can copy the data with Ctr+C.
- On the target: paste the data to a text file and decode it with any available decoder.
Python-based solution
First, on the source machine fire up a Python console and type:
base64data = open('myfile.jpg','rb').read().encode('base64')
open('myfile.txt','w').write(base64data)
Next, open the file myfile.txt
with a text editor and copy the contents. Then on the target machine paste the contents into a new file named myfile.txt
and in a console type:
data = open('myfile.txt').read().decode('base64')
open('myfile.jpg','wb').write(data)
These snippets can be extracted to scripts in order to avoid typing every time.
GUI based solution (Windows)
If you don't have Python or if both your machines are running Windows and you have Total Commander installed then the steps are simpler:
-
On the source: select your file and then pick Files > Encode file. A corresponding
.b64
will be created in the other panel - open it (F3) and copy the contents (Ctr+a, Ctr+c). -
On the target: paste into a new file with
.b64
extension and then use Files > Decode file.
Another alternative app is notepad++ with the built-in mimetools plugin that does base64 encoding/decoding (Plugins -> Mime Tools > 64 Encode/Decode).
Command line solutions (OSX, Linux, Windows)
OSX and most Linux systems typically come with more than one flavour of console base64 encoders. This should work ootb without having to install anything:
## encode to base64
openssl base64 -in myfile.jpg -output myfile.jpg.b64
## OR on some systems `-out` should be used instead of `-output`
openssl base64 -in myfile.jpg -out myfile.jpg.b64
## encode to base64 on Windows (recent versions)
certutil -encode myfile.jpg myencodedfile.jpg.b64
## decode from base64
openssl base64 -d -in myfile.jpg.b64 -output myfile.jpg
## OR on some systems `-out` should be used instead of `-output`
openssl base64 -d -in myfile.jpg.b64 -out myfile.jpg
## decode base64 on Windows
certutil -decode myencodedfile.jpg.b64 myfile.jpg
Omitting the -output...
part will print to standard output.
Another ootb utility present both in OSX and Ubuntu:
## encode to base64
base64 < myfile.jpg > myfile.jpg.b64
## decode from base64 (Linux) (note the lowercase 'd')
base64 -d < myfile.jpg.b64 > myfile.jpg
## decode from base64 (OSX) (note the uppercase 'D')
base64 -D < myfile.jpg.b64 > myfile.jpg
Piping directly to clipboard (avoiding intermediary files)
It is possible to encode directly to the clipboard if you have the corresponding command line tools on the source/target OS.
On OSX there are the built-in pbcopy
and pbpaste
, on Linux (in xorg), there is xclip, and on Windows there is clip.exe, which means that encoding a file to clipboard can be simplified to (e.g. for OSX):
base64 < myfile.jpg | pbcopy
And the proper way...
Jokes aside now.. If you need to transfer files between two machines (no matter what you use to connect) then use SSH which provides scp
. If one or both boxes are behind firewalls/routers then use a jump server (i.e. an internet-exposed server, could be a VPS). You'll need to have an always-on link from your destination box to the jump server, configure port forwarding and then use SCP over the forwarded port on the jump server. In a A->B->C hop scenario you'll need an SSH client on A, and running SSH servers on both B and C.
Once you have the outgoing connection and port forwarding configured from box C (which can be tricky if you've never done it before) you can connect over SSH from box A with a profile defined in your ~/.ssh/config
file similar to:
Host jump
Hostname hostname_C
User username_C
Port portnumber_C
ProxyJump username_B@hostname_B:portnumber_B
Once you have it all set up you can copy files/folders simply with:
scp -r /some/local/dir jump:remote_dir
or from remote to local:
scp -r jump:remote_dir/subdir /my/local/machine/path
remote_dir
will be relative to the user's home.
NOTE: This does not cover all the steps, as this is beyond the scope of the original question, but you can use for example Chrome Remote Desktop in order to establish the SSH link from your box C to box B (the jump server), and then from box A 'transparently' connect to C via B.
And finally, if you want a nicer text-mode GUI than
scp
then consider using Midnight Commander —mc
(apt install mc
) where you can connect e.g. with Left -> Shell Link: type your target box user@IP or your alias configured in~/.ssh/config
such asjump
in the example above.
Transfer files over SSH with Midnight Commander:
Solution 3:
Yes, yes you can. As of very recently (This week? This month? Just now today? [This is the first time I've seen it]) Chrome Remote Desktop has moved from being a stand-alone program you download and launch through the Chrome Store, to an in-browser app you launch from a website: https://remotedesktop.google.com.
[Tested 27 June 2019]
With this change comes a brand-new file transfer feature! When you log in you have this menu on the right-hand side of your screen:
If you don't see that, hover on the right until you see a little blue arrow pointing to the left, and click it, as this menu is hide-able.
1. To download from remote to local:
To Download a file from the remote machine to your local machine (host) click the "Download file" button. It will open up a "Download File" file manager window on the remote machine. Choose a file and click "Open." The file is transferred through the network and a GUI file manager "Save File" window will magically open up on your local (host) machine. Choose a location and save the file.
Done. The file is on your local machine in the folder you chose to save it in.
2. To upload from local to remote:
To Upload a file from your local (host) machine to your remote machine, click the "Upload file" button. It will open an "Open File" file manager window on your local machine. Choose a file (bug alert: you MUST click on the file again with your mouse even if it is already selected or else this won't work for me) and click "Open". Under the "File Transfer" dialog shown above, you'll see an "Uploading" indicator show up with a file transfer progress bar. When completed, you'll see the following notification pop up on the bottom of your remote desktop screen: "Upload complete. Look for the file on the remote device's desktop."
Done. The file is on your remote computer's desktop.
Solution 4:
To transfer files, just use your Google Drive. You have to be logged into your Google account in order to use Chrome Remote Desktop, so just open Google Drive, drop your file into it. Once it uploads, open Google Drive on your remote computer and pull it out of Google Drive to the desktop or folder of your choice!