Skip to content
AI Voice Agents
AI Voice Agents11 min0 views

Flutter flutter_webrtc + AI Voice Agents (2026): Production Stack

flutter_webrtc is the dominant cross-platform Flutter WebRTC plugin in 2026. Here is how AI voice agent apps build it with callkeep, FCM/PushKit, and pipecat_flutter.

Flutter has had production-grade WebRTC for years thanks to flutter_webrtc, and 2026 added pipecat_flutter, which wraps the streaming-LLM dance (STT → LLM → TTS) into one plugin. Combined with flutter-webrtc/callkeep, you can ship a cross-platform AI voice agent client in a single Dart codebase.

Background

flutter_webrtc is the official-by-convention Flutter WebRTC plugin (pub.dev: flutter_webrtc) and bridges to libwebrtc on iOS, Android, macOS, Windows, Linux, and the web. In April 2026, the Flutter WebRTC org also ships callkeep (CallKit + ConnectionService), and the broader ecosystem now includes pipecat_flutter 0.2.0, which abstracts the AI voice loop with sub-500 ms latency, transcript inspection, and mid-stream function calling. LiveKit and Stream both publish first-class Flutter SDKs that ride on flutter_webrtc.

For AI voice agent apps, this means you can pick your level of abstraction: raw flutter_webrtc + your own signaling, LiveKit Flutter for media routing, or pipecat_flutter for the whole STT-LLM-TTS pipeline.

Architecture

```mermaid flowchart LR Push[FCM / PushKit] --> Flutter[Flutter App] Flutter -- displayIncomingCall --> Callkeep[flutter-webrtc/callkeep] Callkeep -- answer --> Flutter Flutter -- getUserMedia --> WebRTC[flutter_webrtc RTCPeerConnection] WebRTC -- DTLS-SRTP --> Gateway[Pion Go gateway 1.23] Gateway -- NATS --> Pod[6-container agent pod] ```

CallSphere implementation

We evaluate Flutter for cross-platform partner apps that need to embed our AI agents:

Hear it before you finish reading

Talk to a live CallSphere AI voice agent in your browser — 60 seconds, no signup.

Try Live Demo →
  • Real Estate (OneRoof) — Partner brokerages embed our Flutter SDK to add CallSphere voice agents inside their own apps. The signaling and media path is identical: Pion Go gateway 1.23 → NATS → 6-container pod (CRM, MLS, calendar, SMS, audit, transcript). See /industries/real-estate.
  • Healthcare — Healthcare partner apps use the OpenAI Realtime path with HIPAA-safe payloads. See /industries/healthcare and /lp/healthcare.
  • /demo browser path — Same agents, plain Chrome. See /demo.

37 agents · 90+ tools · 115+ DB tables · 6 verticals · HIPAA + SOC 2 · $149/$499/$1499 · 14-day /trial · 22% affiliate at /affiliate.

Build steps with code

```yaml

pubspec.yaml

dependencies: flutter_webrtc: ^0.13.0 callkeep: ^0.4.0 firebase_messaging: ^15.0.0 ```

```dart // lib/voice_call.dart import 'package:flutter_webrtc/flutter_webrtc.dart'; import 'package:callkeep/callkeep.dart';

final FlutterCallkeep _callkeep = FlutterCallkeep(); RTCPeerConnection? _pc; MediaStream? _localStream;

Future setup() async { await _callkeep.setup(null, { 'ios': {'appName': 'CallSphere'}, 'android': { 'alertTitle': 'Permissions Required', 'alertDescription': 'For incoming calls', }, }); _callkeep.on(CallKeepPerformAnswerCallAction(), _onAnswer); }

void _onAnswer(CallKeepPerformAnswerCallAction event) async { _localStream = await navigator.mediaDevices.getUserMedia({'audio': true}); _pc = await createPeerConnection({ 'iceServers': [{'urls': 'stun:stun.l.google.com:19302'}], }); _localStream!.getTracks().forEach((t) => _pc!.addTrack(t, _localStream!)); // Then negotiate offer/answer with backend } ```

Still reading? Stop comparing — try CallSphere live.

CallSphere ships complete AI voice agents per industry — 14 tools for healthcare, 10 agents for real estate, 4 specialists for salons. See how it actually handles a call before you book a demo.

```dart // On FCM background message FirebaseMessaging.onBackgroundMessage((msg) async { await _callkeep.displayIncomingCall( msg.data['call_id']!, msg.data['from']!, ); }); ```

Pitfalls

  • Forgetting iOS background modes — `voip` and `audio` must be in Info.plist.
  • Skipping minSdkVersion bump — flutter_webrtc requires Android 24+; default Flutter projects are still 21.
  • Using DownloadOnly Pod cache — pod install must complete before `flutter run` on iOS.
  • Web target nuances — flutter_webrtc on web wraps the browser API; certain features (encoded transforms, Insertable Streams) are not yet uniform across mobile and web.
  • Mismatching FCM background handler — On iOS the FCM background message arrives via APNs, not VoIP push; you still need PushKit for the wake-from-killed case.

FAQ

Does pipecat_flutter replace flutter_webrtc? No — it sits on top, abstracting the STT/LLM/TTS pipeline. The transport is still WebRTC.

Can I use LiveKit instead? Yes — LiveKit Flutter SDK is a more managed alternative if you want SFU-routed media and less signaling code.

Does it work on Flutter web? Yes — flutter_webrtc has a web implementation; CallKit/Telecom does not apply on web.

How is the binary size? ~7 MB on iOS, ~9 MB on Android.

Is the New Architecture (Impeller) supported? Yes since flutter_webrtc 0.10.x.

Sources

Try CallSphere voice agents at /demo, see /pricing, or start a /trial.

Share

Try CallSphere AI Voice Agents

See how AI voice agents work for your industry. Live demo available -- no signup required.