**Category:** VoIP
**Difficulty:** Beginner → Intermediate
## What You'll Learn
Voice over Internet Protocol (VoIP) is more than simply making calls over the Internet. Behind every successful VoIP call are several protocols working together to locate users, establish connections, transmit voice, and terminate calls.
In this article, you'll learn how **SIP (Session Initiation Protocol)** establishes a call, how **RTP (Real-time Transport Protocol)** carries voice packets, and how these protocols work together to provide real-time communication.
By the end of this article, you will understand the complete VoIP call flow from the moment a user dials a number until the call ends.
## Learning Objectives
**After reading this article, you will be able to:**
- Understand the end-to-end VoIP call process.
- Explain the purpose of SIP and RTP.
- Identify the different stages of SIP call establishment.
- Understand RTP media flow.
- Learn why codecs are important.
- Understand NAT traversal in VoIP.
- Interpret a basic SIP call flow diagram.
## In This Article
- How does a VoIP call work?
- What is SIP?
- What is RTP?
- Understanding SIP messages
- SIP registration process
- Complete VoIP call flow
- RTP media flow explained
- Understanding codecs
- NAT traversal
- Common VoIP ports
- Frequently Asked Questions
---
## How Does a VoIP Call Work?
Unlike traditional telephones that rely on dedicated circuits, VoIP separates signaling from media transmission.
Two different processes occur during every VoIP call:
**1. Signaling** – Establishes and manages the call.
**2. Media Transport** – Carries the actual voice.
Think of making a phone call like ordering food:
- SIP is the waiter taking your order.
- RTP is the waiter delivering the food.
- The codec determines how the food is packaged.
- The IP network is the road used for delivery.
Each component has a distinct responsibility.
### The Main Protocols
| **Protocol** | **Purpose** |
| --- | --- |
| SIP | Creates, manages, and ends calls |
| RTP | Transmits voice packets |
| RTCP | Monitors RTP quality |
| SDP | Negotiates media information |
Although people often refer to "SIP calls," voice is **not** carried by SIP. SIP only handles signaling.
---
## What Is SIP?
**Session Initiation Protocol (SIP)** is an application-layer signaling protocol defined by the Internet Engineering Task Force (IETF).
Its purpose is to create, modify, and terminate multimedia communication sessions.
SIP is responsible for:
- Registering phones
- Locating users
- Ringing devices
- Negotiating codecs
- Starting calls
- Ending calls
Think of SIP as the receptionist who knows where every employee is located before transferring a call.
---
### How SIP Registration Works
Before an IP phone can receive calls, it must register with the SIP server.
The registration process informs the server:
- Who the user is
- Where the user is currently connected
- Which IP address should receive incoming calls
Without registration, the server has no way to locate the device.
### SIP Registration Flow

Once registration succeeds, the phone becomes available to make and receive calls
---
### Common SIP Messages
During a VoIP call, SIP exchanges several messages.
| **SIP Message** | **Purpose** |
| --- | --- |
| REGISTER | Registers the device |
| INVITE | Starts a call |
| TRYING (100) | Server processing request |
| RINGING (180) | Destination phone is ringing |
| OK (200) | Call accepted |
| ACK | Confirms connection |
| BYE | Ends the call |
| CANCEL | Cancels before answer |
These messages are plain text, making SIP relatively easy to troubleshoot using packet capture tools such as Wireshark.
---
### SIP Call Setup
The call establishment follows these steps:

During this process:
- Alice sends an INVITE request.
- The SIP server locates Bob.
- Bob's phone begins ringing.
- Bob answers.
- Both devices acknowledge the session.
- RTP begins transmitting voice.
Notice that SIP establishes the communication but does not transport the audio.
---
## What Is RTP?
Once SIP completes the call setup, **Real-time Transport Protocol (RTP)** takes over.
RTP carries:
- Voice
- Video
- Real-time multimedia
Unlike SIP, RTP continuously sends small packets throughout the conversation.
Each RTP packet contains:
- Audio payload
- Timestamp
- Sequence number
- Synchronization information
These fields help the receiving device reconstruct audio in the correct order.
### RTP Media Flow

Hundreds of RTP packets are exchanged every second.
If packets arrive late or out of order, the receiving device uses timestamps and sequence numbers to reconstruct the conversation.
---
### Why RTP Doesn't Use TCP
RTP normally runs over UDP instead of TCP.
Why?
Voice communication values **speed** more than perfect reliability.
TCP retransmits lost packets.
For file downloads, this is desirable.
For voice communication, retransmitting a packet several hundred milliseconds later would sound unnatural because the conversation has already moved on.
Instead, RTP accepts occasional packet loss to maintain smooth, real-time communication.
---
## Understanding Codecs
A codec determines how voice is encoded before transmission.
Different codecs balance audio quality against bandwidth consumption.
| **Codec** | **Audio Quality** | **Bandwidth** | **Typical Use** |
| --- | --- | --- | --- |
| G.711 | Excellent | High | LAN, Enterprise |
| G.729 | Good | Low | WAN Links |
| Opus | Excellent | Adaptive | Modern VoIP |
| G.722 | HD Voice | Medium | Business Phones |
The codec is negotiated during SIP call setup using **Session Description Protocol (SDP)**.
Both endpoints must agree on a compatible codec before RTP begins transmitting media.
---
## What Is SDP?
SIP establishes the call, but it needs a way to describe the media session.
This is where **Session Description Protocol (SDP)** comes in.
SDP tells the other endpoint:
- Which codec to use
- Which RTP port to send audio to
- Which IP address will receive media
- Supported media types (audio, video, etc.)
Without SDP, SIP would establish a call but the devices would not know how to exchange media.
---
## Understanding NAT Traversal
Many businesses place their VoIP devices behind Network Address Translation (NAT).
While NAT conserves public IP addresses, it can interfere with SIP and RTP because private IP addresses are not routable on the public Internet.
To overcome this, VoIP deployments commonly use:
**1. STUN**
- Allows devices to discover their public IP address.
**2.TURN**
- Relays media when direct communication is not possible.
**3.ICE**
- Tests multiple communication paths and selects the best available route.
- These technologies help ensure successful media flow across NAT environments.
## Common VoIP Ports
| **Protocol** | **Default Port** |
| --- | --- |
| SIP | UDP/TCP 5060 |
| SIP TLS | TCP 5061 |
| RTP | Dynamic (typically 10000–20000) |
| RTCP | Dynamic |
Administrators often configure firewalls to permit these ports for successful VoIP communication.
## Complete VoIP Call Flow
The following diagram summarizes the entire process.

This sequence illustrates how SIP and RTP work together:
- SIP establishes the session.
- SDP negotiates the media.
- RTP transports the audio.
- RTCP monitors quality.
- SIP terminates the session when the conversation ends.
---
## Common Call Quality Issues
Even with correct SIP signaling, poor media quality can occur due to network conditions.
| **Issue** | **Description** | **Possible Cause** |
| --- | --- | --- |
| Latency | Delayed audio | Congested network |
| Jitter | Uneven packet arrival | Network instability |
| Packet Loss | Missing audio | Poor connectivity |
| Echo | Voice reflected | Acoustic or gateway issues |
| One-Way Audio | Only one party hears audio | NAT or firewall misconfiguration |
Proper Quality of Service (QoS), bandwidth planning, and firewall configuration can significantly improve VoIP performance.
---
## Key Takeaways
- SIP establishes, manages, and terminates VoIP calls.
- RTP carries the actual voice packets after the call is connected.
- SDP negotiates codecs and media parameters during call setup.
- RTP typically uses UDP to minimize latency.
- Codecs influence both bandwidth usage and audio quality.
- NAT traversal technologies such as STUN, TURN, and ICE enable reliable communication across private networks.
- Understanding the interaction between SIP and RTP is essential for troubleshooting VoIP systems.
---
## Frequently Asked Questions
**1.Does SIP carry voice traffic?**
- No. SIP is a signaling protocol that establishes and manages calls. The actual voice is transmitted using RTP.
**2.Why does RTP use UDP instead of TCP?**
- UDP minimizes latency by avoiding retransmissions, making it better suited for real-time voice communication where timely delivery is more important than perfect reliability.
**3.Can RTP work without SIP?**
- Yes. RTP is independent of SIP and can be used with other signaling protocols such as H.323 or WebRTC. However, SIP is the most widely used signaling protocol in modern VoIP deployments.
**4.What happens if RTP packets are lost?**
- Small amounts of packet loss may go unnoticed, but excessive loss can result in choppy audio, gaps in conversation, or degraded voice quality.
**5.What is the role of RTCP?**
- RTCP (Real-time Transport Control Protocol) works alongside RTP to provide statistics on packet loss, jitter, latency, and overall call quality, helping administrators monitor VoIP performance.
# Continue Learning
Now that you understand how SIP establishes calls and RTP carries voice traffic, the next step is to evaluate why organizations adopt VoIP and the considerations involved.
**Next Article:** [***VoIP Components Explained: IP Phones, IP PBX, SIP Trunks, and Gateways***](https://bual.asia/blog/article-3-voip-components-explained-ip-phones-ip-pbx-sip-trunks-and-gateways)
In the next article, you'll learn:
- The role of each VoIP component
- How IP phones communicate with an IP PBX
- What SIP trunks do
- When VoIP gateways are required
- A typical enterprise VoIP architecture
## References
- [IETF RFC 3261 – SIP: Session Initiation Protocol](https://www.rfc-editor.org/rfc/rfc3261)
- [IETF RFC 3550 – RTP: A Transport Protocol for Real-Time Applications](https://www.rfc-editor.org/rfc/rfc3550)
- [IETF RFC 4566 – Session Description Protocol (SDP)](https://www.rfc-editor.org/rfc/rfc4566)
How VoIP Works: SIP, RTP & Media Flow
Learn how VoIP calls work behind the scenes—from SIP signaling and SDP media negotiation to RTP voice delivery. This guide explains call flow, codecs, NAT traversal, ports, and common quality issues for reliable VoIP communication.