This is an experimental technology
Because this technology's specification has not stabilized, check the compatibility table for usage in various browsers. Also note that the syntax and behavior of an experimental technology is subject to change in future versions of browsers as the specification changes.
Draft
    This page is not complete.
The RTCIceCandidate interface of the the WebRTC API represents a candidate Internet Connectivity Establishment (ICE) server for establishing an RTCPeerConnection.
Constructors
- RTCIceCandidate()
- Creates an RTCIceCandidateobject.
Properties
- RTCIceCandidate.candidateRead only
- A DOMStringrepresenting the transport address for the candidate that can be used for connectivity checks. The format of this address is acandidate-attributeas defined in RFC 5245. This string is empty ("") if theRTCIceCandidaterepresents a "end of candidates" indicator.
- RTCIceCandidate.foundationRead only
- Returns a unique identifier that allows ICE to correlate candidates that appear on multiple RTCIceTransportobjects.
- RTCIceCandidate.ipRead only
- Returns the IP address of the candidate.
- RTCIceCandidate.portRead only
- Returns the port of the candidate.
- RTCIceCandidate.priorityRead only
- Returns the assigned priority of the candidate.
- RTCIceCandidate.protocolRead only
- Returns the protocol used by the candidate, either udp or tcp.
- RTCIceCandidate.relatedAddressRead only
- For a candidate that is derived from another, such as a relay or reflexive candidate, the relatedAddressis the IP address of the candidate that it is derived from. For host candidates, therelatedAddressisnull.
- RTCIceCandidate.relatedPortRead only
- For a candidate that is derived from another, such as a relay or reflexive candidate, the relatedPortis the port of the candidate that it is derived from. For host candidates, therelatedPortisnull.
- RTCIceCandidate.sdpMidRead only
- If not null, this contains the identifier of the "media stream identification" (as defined in RFC 5888) for the media component this candidate is associated with.
- RTCIceCandidate.sdpMLineIndexRead only
- If not null, this indicates the index (starting at zero) of the media description (as defined in RFC 4566) in the SDP this candidate is associated with.
- RTCIceCandidate.tcpTypeRead only
- If protocolistcp,tcpTyperepresents the type of TCP candidate. Otherwise,tcpTypeisnull.
- RTCIceCandidate.typeRead only
- One of host,srflx,prflx, orrelay.
Specifications
| Specification | Status | Comment | 
|---|---|---|
| WebRTC 1.0: Real-time Communication Between Browsers The definition of 'RTCIceCandidate' in that specification. | Working Draft | Initial definition. | 
Browser compatibility
| Feature | Chrome | Edge | Firefox (Gecko) | Internet Explorer | Opera | Safari (WebKit) | 
|---|---|---|---|---|---|---|
| Basic support | (Yes) | (Yes) | 22 (22) | 
| Feature | Android | Android Webview | Edge | Firefox Mobile (Gecko) | Firefox OS | IE Mobile | Opera Mobile | Safari Mobile | Chrome for Android | 
|---|---|---|---|---|---|---|---|---|---|
| Basic support | ? | (Yes) | (Yes) | (Yes) |