Guide

How FileCourier Works

A plain-language explanation of the technology behind private, serverless file transfer.

The Transfer in Three Steps

No plugins, no installs, no accounts. Just two browser tabs and a link.

1
📤
Sender opens FileCourier

A unique peer ID is registered with the signaling server. A share link containing that ID is shown to the sender. The sender adds up to 10 files to the queue.

2
🔗
Receiver opens the link

The receiver's browser connects to the signaling server, locates the sender by peer ID, and exchanges ICE candidates to find the best network path.

3
⚡
File streams directly

The WebRTC DataChannel opens. The sender offers the file, receiver accepts, and bytes flow in 64 KB chunks — encrypted, peer-to-peer.

File Confirmation Flow

The receiver always sees what's coming before a single byte is transferred.

✓
Connection popup

Both sides see a "Connection Established" confirmation before anything happens.

📄
File offer

Sender proposes each file with its name, size, and type. Receiver sees this before accepting.

✔
Accept or decline

Receiver clicks Accept to start the download, or Decline to skip that file. Sender is notified either way.

📤
Transfer begins

Only after acceptance does the sender start streaming. No surprise downloads.

Crossing NAT — STUN & TURN

Most devices sit behind NAT routers that hide their real IP address. WebRTC uses ICE to solve this.

📶
Phase 1 — STUN

Each browser contacts a STUN server to discover its public IP address. Both sides exchange these addresses and attempt a direct connection (hole-punch). This succeeds for around 90% of home WiFi and broadband pairs worldwide.

🔄
Phase 2 — TURN Relay

If direct fails (symmetric NAT, CGNAT, strict firewall), the app automatically offers a relay button to the receiver. When clicked, all data flows through a TURN relay server — still encrypted — until it reaches the other browser.

Relay button: Only the receiver sees the relay button — the sender's link stays valid throughout. Clicking relay does not refresh the page or generate a new link.
Some mobile carriers (notably certain South/South-East Asian networks) block the IP ranges of public TURN relay servers. If relay also fails, switch the mobile device to WiFi — the connection establishes immediately.

How Files Are Saved

FileCourier tries three methods in order, falling back if the browser doesn't support the previous one.

Tier Method Browsers Size limit
1 StreamSaver.js — service worker streams directly to disk Chrome, Edge Unlimited
2 File System Access API — native browser write stream Chrome, Edge Unlimited
3 In-memory Blob — accumulate in RAM, save at end All browsers 512 MB max

Technical Architecture

📡
Signaling server

PeerJS cloud (0.peerjs.com) handles only peer discovery — peer IDs and ICE candidates. After the WebRTC channel opens, the signaling server is never contacted again. File data never passes through it.

📊
64 KB chunks + backpressure

Files are split into 64 KB chunks. If the DataChannel's send buffer exceeds 8 MB, sending pauses until the buffer drains. This prevents out-of-memory errors on the sender for very large files.

🔄
Auto-reconnect

If the receiver switches networks (WiFi to mobile or vice versa), the app detects the change and automatically retries the connection up to three times with a short delay.

🔒
DTLS-SRTP encryption

WebRTC mandates DTLS encryption on every DataChannel. There is no opt-out. All file chunks are encrypted in transit, even when relayed through a TURN server.

Ready to try it?

No account, no install. Open FileCourier and share a link in seconds.

Start a Transfer →