SIP (Session Initiation Protocol, RFC 3261) is a text-based, request/response signalling protocol that establishes, modifies and terminates real-time media sessions such as voice and video calls. It defines user agents, proxies, registrars and redirect servers, and carries the session description (SDP) that negotiates the media the endpoints will exchange.
What SIP is
SIP is an application-layer control protocol for creating and managing multimedia sessions over IP — most commonly voice (VoIP), video and messaging. It does not carry the media itself; it negotiates and controls sessions, then the media flows separately over RTP. Its design is deliberately HTTP-like: human-readable text messages, request methods and three-digit response codes, and URI-based addressing (sip:alice@example.com). This familiarity, and its independence from the underlying media, made SIP the standard signalling protocol for VoIP, SIP trunking and VoLTE/IMS.
SIP entities
SIP defines a small set of logical roles. A User Agent is an endpoint: it acts as a User Agent Client (UAC) when it sends a request and a User Agent Server (UAS) when it responds. Proxies route requests toward the destination and can fork them to several targets. A registrar records where a user is currently reachable (their Contact) via REGISTER. A redirect server returns an alternative location rather than forwarding. A Back-to-Back User Agent (B2BUA) terminates and re-originates a call, sitting in the middle of both signalling and often media — the model used by session border controllers and PBXs.
| Entity | Role |
|---|---|
| UAC | User Agent Client — originates a request |
| UAS | User Agent Server — responds to a request |
| Proxy | Routes/forwards requests, may fork to multiple targets |
| Registrar | Records a user's current Contact (via REGISTER) |
| Redirect server | Returns an alternative location (3xx) instead of forwarding |
| B2BUA | Terminates and re-originates a call (SBC, PBX) |
Transactions and dialogs
SIP has two levels of state. A transaction is a single request and its responses (for example an INVITE and the 100/180/200 it triggers), identified by the Via branch parameter. A dialog is the longer peer-to-peer relationship a call represents, identified by the combination of Call-ID, the From tag and the To tag. INVITE creates a dialog; subsequent in-dialog requests (re-INVITE, BYE) reference it. Understanding this split is essential to reading a SIP flow, because responses and retransmissions are matched at the transaction level while the call lives at the dialog level.
Transport and ports
SIP runs over UDP, TCP or TLS, and (less commonly) SCTP or WebSocket for WebRTC. The IANA default port is 5060 for UDP and TCP, and 5061 for SIP over TLS (signalled by a sips: URI). UDP is common for its low overhead, but large messages that exceed the path MTU should use TCP, and any deployment crossing untrusted networks should use TLS for the signalling and SRTP for the media. Transport is selected per hop and can change along the path.
| Transport | Default port | Notes |
|---|---|---|
| UDP | 5060 | Low overhead; switch to TCP above the MTU |
| TCP | 5060 | For large messages and reliable delivery |
| TLS (sips:) | 5061 | Encrypted signalling |
| WSS (WebSocket) | — | SIP over secure WebSocket for WebRTC |
Frequently asked
What is SIP used for?
SIP sets up, modifies and tears down real-time media sessions over IP — voice and video calls, SIP trunking between phone systems and carriers, and VoLTE/IMS call control. It handles the signalling; the actual audio or video travels separately over RTP.
Is SIP like HTTP?
By design. SIP borrows HTTP's request/response model, text-based messages, header syntax, three-digit status codes and URI addressing. The semantics differ — SIP manages stateful sessions across proxies and both endpoints can originate requests — but the surface will look familiar to anyone who knows HTTP.
What is the difference between a SIP transaction and a dialog?
A transaction is one request plus its responses, matched by the Via branch. A dialog is the ongoing call relationship, identified by Call-ID plus the From and To tags. A single dialog (a call) contains several transactions — INVITE, then later BYE.
What port does SIP use?
The IANA default is 5060 for SIP over UDP and TCP, and 5061 for SIP over TLS. Media (RTP) uses a separate, dynamically negotiated UDP port range described in the SDP, not the SIP signalling port.
Does SIP carry the voice?
No. SIP only carries signalling — it negotiates the session and the media parameters via SDP. The voice or video itself flows over RTP (or SRTP when encrypted) directly between the endpoints or through a media relay, on separate ports from the SIP messages.
Source specifications
The published standards this page is grounded in. Opens in a new tab.