Behind Video Call Glitches #2
the technique that let's you facetime your partner
In the first part, we ended with a problem: both you and your friend are sitting behind routers with private IP addresses. You want to video call each other, but neither of your devices can be reached directly from the internet.
Routers are doing their job, protecting devices on the inside. That’s just too much security for 2 people to connect.
So how do apps like Zoom and WhatsApp make this work?
You are Me, I am You
Inside your home network, your router gives your device a private IP, something like 192.168.1.5. But here’s the weird part:
My laptop might also be 192.168.1.5.
Your neighbor’s laptop might be 192.168.1.5.
Millions of devices worldwide might be 192.168.1.5.
It works because those addresses only matter inside their own networks - like “Apartment 5” existing in millions of buildings without confusion. Once traffic leaves your home, your router replaces that private IP with your public IP using something called NAT (Network Address Translation), the trick that lets many devices share one internet address.
Your router also remembers who asked for what. If you open Google, it keeps a note: “This reply belongs to this device.” When the response comes back, it knows exactly where to send it.
But this system has a catch:
It only works for connections you initiated.
Wait… Your Phone Can’t Just Call Mine
If your device tried sending packets straight to mine, my router wouldn’t know who they belonged to. There’s no matching “request note,” so it simply discards them.
This is why most of the internet uses the client-server model: everyone talks to a public server that sits out in the open. That works great for websites and emails, but routing live video through giant servers would mean huge bandwidth costs and more delay.
What we really want is a direct connection between our devices:
faster
more efficient
more private
So how do two devices that can’t accept incoming traffic… suddenly talk directly?
Fool That Warden
Routers allow replies from places your device recently contacted. So if your device sends even one packet to my public address, your router temporarily allows packets back from that address.
If both devices do this to each other, each router believes,
“Oh yes, my device is already talking to that place, let the reply through.”
And suddenly, there’s a path between us.
This technique is called hole punching, and it powers most peer-to-peer calls.
Magical Awakening
Before any of this happens, the app needs a way to say:
“Hey, someone wants to call you.”
This uses a completely different communication path called signaling.
When you open WhatsApp, Zoom, or FaceTime, your device quietly maintains a lightweight, always-on connection to the app’s server. It’s like checking in at a hotel front desk:
“I’m online. If anyone needs me, contact me here.”
So when you tap “Call,” your device sends a simple message to the server:
“Connect me to this person.”
The server forwards that to my device over its open connection. My phone rings. If I decline, the conversation ends right there, no networking magic yet.
When I press Answer, then the real work starts.
Self Discovery
Once we both agree to connect, each device contacts a STUN server to learn how it appears from outside the network.
It basically asks:
“What’s my public IP and port right now?”
The STUN server replies:
“You appear as 198.51.100.25:54782.”
Now both devices:
Learn their own public addresses
Exchange that info through the app’s signaling server
Attempt hole punching to talk directly
If it works, video and audio now flow directly between devices over fast, lightweight UDP, instead of bouncing through a giant company server. This media channel is encrypted end-to-end.
Last Measure
Sometimes, hole punching simply doesn’t work, especially behind strict corporate networks or mobile carrier NATs.
In that case, the app falls back to TURN servers, which act as relays. Both devices stream to the TURN server, which forwards traffic between them. It’s slower and more expensive, so apps only use it when necessary, but it guarantees calls still work.
Connecting…
When your app shows that little Connecting…, this is happening:
Devices ask STUN for their public addresses
They share those through the signaling server
They both send packets to each other to punch router holes
If successful → direct peer-to-peer connection
If not → fallback to TURN relay
However you may see it, it’s just magical to be able to appear in front of anyone anytime, crazy times we live in
And that’s a wrap for today, and before I say goodbye for today, here’s a quote I’ve been pondering,
"A great relationship is not only finding the person you have fun with, but also finding the person you want to be bored with. The beauty of long-term relationships is often hidden in boring, ordinary moments."
Please don’t forget to share it with your friends, family, and strangers.
Have a Great Day 💖




Lol I love the 'punching router holes' phrase
Also, that quote on boredom. I think thats just the human version of a 'Keep-Alive' packet. Low data transfer, but it proves the connection is stable.
Loved the BTS of video calls btw. Even tho I'm someone who prefers text all the way xD