Not logged in

filegive: Easy sending of files, point-to-point

How to send a file from my computer to my friend's computer, secure, simple and without a third-party in the link? Many people ask this question: xkcd 949. filegive will work, or can be made to work, in many situations.

The receiving side only needs a browser (or anything that can browse using http or https). The sender only needs to call filegive, and give the resulting URL to the receiver by chat, for example.

In fact there is even a 'receiving' mode (-R), so the receiver runs filegive getting a URL that can send to the sender. The sender visiting the URL with a browser is offered an upload html form.

The connection goes point-to-point, and not through a third party server, like, or services like dropbox. Additionally, https provides easy end-to-end security, and extra options like rate limit makes it an improvement over other usual point-to-point methods like dcc send (irc, jabber, ...).

How to use it

In its basic usage, if you want to send a file to your colleague in your network, you simply have to:

$ filegive myfile.webm
Certificate SHA1 (s: filegive auulftfq): CD:44:9E:17:1D:99:9D:6A:F3:F9:03:F0:61:A5:FD:CB:D9:5C:2D:6A
█ ▄▄▄▄▄ █ ▄█ ▀ ▄  █▄▀▄█ ▄▄▄▄▄ █
█ █   █ █▄█▄ ▄▄█▀▄▀██▄█ █   █ █
█ █▄▄▄█ █ ▀█▄█  █ ▄▀  █ █▄▄▄█ █
█▄▄▄▄▄▄▄█ █ █ ▀▄▀▄█▄▀ █▄▄▄▄▄▄▄█
██▀▄▀▀█▄▄▄▀█▀▄█▄▀ ▄███    ▀▄▄ █
█▄█▀██ ▄▀█▀ ▄  █  █▄▄▄█▄ █▄▄▄▄█
█▀▀█▄  ▄▀     ██  ▄▄▀  █  ▄▀ ▀█
█  ▀▄▀▀▄▄▀█████▄ ████▀██ ▄██▀▀█
█▀▄██▄▄▄▀  ▀▀  █▀  ▀  ▄█ ▀▄▀▀▀█
█▀▀▄▀▀▀▄ ▄▄█▀▄▄▄▄ ▄▄ ▄▄  ▄██▄██
█▄██▄▄▄▄▄▀█████  ▄█▄▀ ▄▄▄ ▀▄▄▄█
█ ▄▄▄▄▄ █▄ ▄█▄ ▄   ▀▀ █▄█ ██▄██
█ █   █ ██▀█▄▀▀▀▀▀▀▄ ▄▄  ▄▄ ▀ █
█ █▄▄▄█ █▄█ ▀▀█▀▀▀▄▀▀█ ▀█▀ █▀▀█

You then only have to send the https url to your friend, and the sending will start. To traverse the Internet, you may need to add some parameters, and maybe configure your network access point. Learn more at Examples of usage.


The SHA1 long lines in the previous example are to be used to achieve security, so noone can see what do you transfer. Filegive uses widely spread cryptography (SSL/TLS) to achieve secrecy end to end, and as it is available in most browsers, it is easier to use and only one side needs filegive installed.

To learn more about the security in filegive, please read the Security page.

Use cases

I wrote this program because I was ashamed not being able to answer how to send a file through the Internet. I have principles, so I couldn't advertise 'dropbox', or 'skype'. At the end, I came up with filegive.

I find it very comfortable in these situations:

All that, without the other side having to be a computer geek to make the transmission effective.

More options

filegive v0.8.0 - Copyright 2020 Lluis Batlle i Rossell - AGPLv3+
usage: ./filegive [options] <file|dir|->
  -A          use NAT-PMP
  -D <str>    directory in URL (X means random char, XXXXXX default)
  -d          make the browser download to a file
  -G          manual gateway IP address (for NAT-PMP)
  -N          don't exit at end of downloads
  -P <port>   port to bind to (local, UPnP, NAT-PMP, ...)
  -R          receive a file, not send (http upload, in browser side)
  -ca         use the CA certificate instead of generating one
  -e <h:p>    known external address (ip:port)
  -g          regenerate CA certificate
  -i          interactive mode, you acknowledge download attempts
  -n <n>      number of destination users (default 1)
  -p          disable https serving files
  -r          rate limit to these KiB/S (0=unlimited, default)
  -s <host>   use ssh tunnel (requires non-default sshd_config)
  -ss <host>  use ssh tunnel, with socat at the remote side
  -sn <host>  use ssh tunnel, with GNU netcat at the remote side
  -t          UPnP/NAT-PMP forwarding timeout in secs (0, unlimited)
  -u          use UPnP
Env vars:
  FILEGIVE_START_PORT   Serve at this port or next if busy


Last release source: filegive-0.8.0.tar.gz (82 KB, signature, key 0x7CBD1DA5, sorry for the wrong mimetype; try to get the signature with curl or wget). Changelog. It should work on GNU/Linux, BSD, MacOSX and Windows. Tested on GNU/Linux and Windows

Trunk source: filegive-trunk.tar.gz

License: AGPLv3+

Windows prebuilt binaries

Windows i386 binary: (1.9MB, signature, Key 0x0C091D95)

You can Drag&Drop files to the filegive.exe, and it will give you a url. The URL is put on the clipboard automatically, so you can just Drag&Drop the file over it, and paste the clipboard contents into your messaging system.

You can also make a shortcut to filegive.exe adding the "-u" parameter; then Drag&Drop over it will provide a public URL if you have a UPnP-enabled router. Similar for any other configuration required.

Attention: On Windows, using UPnP, you should exit the program typing 'q', instead of ctrl-c or closing the cmd window. Otherwise the UPnP temporary forwarding won't be removed. You'll have a reminder about that running filegive.

To get UPnP working, you may need to tweak your Windows Firewall to let filegive talk with your router.

Third party contributions

Matthias Albrecht (biosmanager) wrote a GUI for Windows, written in .NET, and released also under AGPLv3+.

Download: FileGiveGUI Source: FileGiveGUI v0.2

Build instructions

Download and install the go toolkit.

In the directory of the code, run:

# set up GOPATH if you don't have it
mkdir ~/go
export GOPATH=$HOME/go

go get
go build

Using nix? nix-env -iA filegive -f .


If you like this software, you can donate a bit to it with flattr. Look for the button at the very top-left of tihs page.

Author: Lluís Batlle i Rossell <> (remove all 'xa'! It's an antispam trick!)