+3
日增长
16,900
stars
1,922
forks
258
watchers
2,368
prs
1,094
issues
175
releases
README
Pion WebRTC
A pure Go implementation of the WebRTC API
New Release
Pion WebRTC v4.0.0 has been released! See the release notes to learn about new features and breaking changes.
If you aren't able to upgrade yet check the tags for the latest v3 release.
We would love your feedback! Please create GitHub issues or Join the Discord to follow development and speak with the maintainers.
-----
Usage
Go Modules are mandatory for using Pion WebRTC. So make sure you set export GO111MODULE=on, and explicitly specify /v4 (or an earlier version) when importing.
example applications contains code samples of common things people build with Pion WebRTC.
example-webrtc-applications contains more full featured examples that use 3rd party libraries.
awesome-pion contains projects that have used Pion, and serve as real world examples of usage.
GoDoc is an auto generated API reference. All our Public APIs are commented.
FAQ has answers to common questions. If you have a question not covered please ask in Discord we are always looking to expand it.
Now go build something awesome! Here are some ideas to get your creative juices flowing:
Send a video file to multiple browser in real time for perfectly synchronized movie watching.
Send a webcam on an embedded device to your browser with no additional server required!
Securely send data between two servers, without using pub/sub.
Record your webcam and do special effects server side.
Build a conferencing application that processes audio/video and make decisions off of it.
Remotely control a robots and stream its cameras in realtime.
Need Help?
Check out WebRTC for the Curious. A book about WebRTC in depth, not just about the APIs.
Learn the full details of ICE, SCTP, DTLS, SRTP, and how they work together to make up the WebRTC stack. This is also a great
resource if you are trying to debug. Learn the tools of the trade and how to approach WebRTC issues. This book is vendor
agnostic and will not have any Pion specific information.
Pion has an active community on Discord. Please ask for help about anything, questions don't have to be Pion specific!
Come share your interesting project you are working on. We are here to support you.
One of the maintainers of Pion Sean-Der is available to help. Schedule at siobud.com/meeting
He is available to talk about Pion or general WebRTC questions, feel free to reach out about anything!
Features
PeerConnection API
Go implementation of webrtc-pc and webrtc-stats
DataChannels
Send/Receive audio and video
Renegotiation
Plan-B and Unified Plan
SettingEngine for Pion specific extensions
Connectivity
Full ICE Agent
ICE Restart
Trickle ICE
STUN
TURN (UDP, TCP, DTLS and TLS)
mDNS candidates
DataChannels
Ordered/Unordered
Lossy/Lossless
Media
API with direct RTP/RTCP access
Opus, PCM, H264, VP8 and VP9 packetizer
API also allows developer to pass their own packetizer
IVF, Ogg, H264 and Matroska provided foTop issues
#9Roadmap76 comments · 2018-06-13#1981What can the Pion team do to make WebRTC easier 23 comments · 2021-10-10#2226Inactive tracks should not be stopped18 comments · 2022-05-18#2424H264 ffmpeg with zerolatency but play with green blocks16 comments · 2023-02-24#3089How does the interceptors work?13 comments · 2025-04-09#1652SampleBuilder can't handle H26412 comments · 2021-01-29#3561v5 Release11 comments · 2026-09-23#2731Generate host candidates with component 1 only when a=rtcp-mux is present11 comments · 2024-04-04
Discussions
#3539Codec55: 100% pure Go video codec & streaming player (Zero CGO, 0 heap allocs/frame, 467 µs scaling)2 comments · 2026-09-15#3400Set webrtc codec preferences1 comments · 2026-03-24#3389Setup track based on codec negotiation0 comments · 2026-03-04#3320Support Continual Gathering1 comments · 2025-12-24#3211Can I use pion/webrtc with Android 5 (API level 21)?0 comments · 2025-08-30#3183Question regarding stream stats1 comments · 2025-07-28#3136Problem with H.265 Video to Chrome via Pion (v4.1.1)2 comments · 2025-06-01#3104How to switch between send video layers in simulcast server-side??1 comments · 2025-04-22
Latest release
v5.0.0-rc.3 v5.0.0-rc.3 2026-11-10Changelog 8cfe1fba4b07c7e151b9e09fd2a9065b163ef2f2 Upgrade ICE to v5.0.0-rc.9, TURN to v6, and STUN to v5 0c8c424aa3fbd1ae6f963654510e381be88d4e53 Refresh codec preferences during renegotiation a3c52d6db94875c68e8714167fa8d092e03bc07e Exercise IPv6 connectivity over loopback UDP 46d898ef7c40ed3061fa3168041d29dbb338c180 Remove note about Go Modules from README 92381cfaf54e6e74a1180ce43d1dacc85d2a0d1b Test reads during RID stream replacement e1bd3b88a10ac89ff7d661a22e6bdb49545787b5 Upgrade to DTLS v4.0.1 a4b3d8e03d3f7aeb31f21edc9431c880cfbc6c95 Skip DTLS HelloVerifyRequest for full-agents