STUN vs TURN: How WebRTC finds a working connection
Blog post from Video SDK
STUN and TURN serve different roles in WebRTC: STUN reveals the public address and port a device’s network presents, giving ICE a candidate for a possible direct connection, while TURN relays media when ICE cannot establish a direct path or relay-only operation is required. NAT behavior and firewalls can prevent direct connections, so a STUN-discovered address alone does not guarantee reachability; ICE checks candidate pairs, including host, server-reflexive, peer-reflexive, and relay candidates, and selects a working pair. Because TURN carries call traffic, it costs more to operate and is generally kept as a fallback; its common ports are 3478 for UDP or TCP and 5349 for TLS or DTLS, though deployments may use alternatives such as 443. Developers can identify whether a live call uses TURN by inspecting the selected candidate pair in browser WebRTC statistics or Chrome’s webrtc-internals. The article also outlines VideoSDK-specific firewall rules and notes that its SDK handles TURN configuration and fallback.
No tracked trend matches for this post yet.
Use this post, company, and trend context to find content marketing opportunities, perform competitive analysis, or address product feature gaps via the Plushcap MCP server or the Plushcap API.