The fastest way to send a file when you're in the same room

WebRTC P2P file transfer sends files directly between browsers without touching a server. When to use it, when not to, and how it actually works.

Z.Tools6 分钟阅读
Og Image

Cloud storage is a reasonable answer to "how do I send a file to someone?" until the other person is sitting across the table from you. Uploading 800MB to a server so it can travel back down to a laptop three feet away is genuinely absurd. The file goes from your machine, up to a data center, back down to the same room. It takes longer, uses more bandwidth, and stores a copy of your file on someone else's infrastructure, even if only temporarily.

Peer-to-peer browser transfer fixes this. The file goes directly from your browser to theirs. No cloud intermediary. The speed depends on your local connection, not your internet upload rate.

How WebRTC actually moves the file

WebRTC is the browser technology behind video calls in apps like Google Meet and Zoom. The same mechanism that streams video between browsers also works for arbitrary data, including files.

The process has two stages. First, signaling: a small server helps both browsers find each other and negotiate a connection. This part touches a server, but only to exchange connection metadata, not file data. Think of it as two people calling a third party to get each other's phone numbers, then hanging up to call each other directly.

Second, once both browsers have exchanged that metadata, they attempt a direct connection. The WebRTC standard uses ICE (Interactive Connectivity Establishment) and STUN servers to figure out each device's public address and find a path through NAT routers. On most home and office networks, this succeeds. The file then travels browser to browser over an encrypted data channel.

The signaling server never sees the file. Once the peer connection is up, the intermediary is out of the picture entirely.

When P2P beats cloud uploads

Same room, large file. This is the main case. If both devices are on the same WiFi network, a P2P transfer can saturate that local network without touching the internet at all. A 1GB video that would take ten minutes to upload and download through cloud storage can transfer in under a minute on a standard home network.

Privacy-sensitive content. Files pass directly between browsers and are never written to a third-party server. If you are transferring documents you would rather not leave sitting in someone's cloud storage, browser-to-browser transfer removes that step. The transfer is also encrypted end-to-end via WebRTC's built-in DTLS.

No account on either side. Most file-sharing services require at least one party to have an account. A 6-digit room code requires nothing. Open the page, share the code, transfer the file.

Sending files to your own phone. The same logic that applies to two people applies to two of your own devices. Opening the page on your laptop and your phone, entering the room code, and dragging a file over is often faster than emailing yourself or using a sync service that may take a moment to propagate.

Conference rooms and coworking spaces. When you need to get a file from your machine to a projector laptop or a colleague's computer at a shared desk, a room code takes about fifteen seconds to set up.

When cloud wins

P2P requires both devices to be online at the same time. You cannot send a file and have the recipient pick it up later. If the person you are sending to is not at their device right now, a cloud service that holds the file until they are ready is the right tool.

The 2GB file size limit also matters. Professional video files, large dataset exports, and disk images often exceed this. Cloud storage handles arbitrarily large files; browser P2P does not.

Finally, sending to multiple recipients is awkward with P2P. You would need to repeat the process for each person. A shareable link that many people can download from simultaneously is better served by cloud storage.

How the room system works

Open the tool. A 6-digit room code is generated automatically. Share that code with the other person verbally, over chat, or through the shareable room link. They open the tool and enter the code.

Once both browsers are in the same room, each side sees the other is present. Drag a file into the browser window or use the file picker. The recipient sees a prompt showing the filename and size, and chooses to accept or reject. This is not automatic. The confirmation step means unexpected transfers cannot happen without the recipient's knowledge.

Files up to 2GB are supported per transfer. Both browser tabs need to stay open for the duration. Navigating away or closing the tab drops the connection.

Comparison with native solutions

AirDrop is faster and smoother for Apple-to-Apple transfers on the same network. It does not require opening a browser or entering a code. The limitation is that it only works between Apple devices, and only when both are on the same local network with AirDrop enabled.

Nearby Share (Android/Windows) follows a similar pattern: fast, no account needed, limited to supported platforms and proximity.

P2P browser transfer fills the gap when the two devices are different platforms, or when the recipient is not on the same network. It also works in environments where Bluetooth and local network discovery are restricted, since it routes through the internet's signaling phase rather than requiring local discovery.

The honest comparison: if both devices are Apple, use AirDrop. If you are mixing platforms, or the other person is anywhere from one room to one country away, browser P2P is the practical option.

The one thing this approach gets right

Most file transfer tools solve the wrong problem. They build elaborate infrastructure around asynchronous delivery: upload now, download later, manage links, set expiration dates. This is useful, but it is overkill for synchronous transfers where both people are available right now.

P2P file sharing accepts the constraint that both sides must be present and turns it into an advantage. No stored copies, no link management, no accounts. The session is temporary by design. When both parties close the tab, nothing persists. For the "I need this file in your hands in the next two minutes" scenario, that simplicity is exactly right.

P2P 文件传输

P2P 文件传输

通过安全的点对点连接在设备间直接传输文件

  • utility
  • file-sharing
  • webrtc
  • p2p

继续阅读