---
title: "Flutter flutter_webrtc + AI Voice Agents (2026): Production Stack"
description: "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."
canonical: https://callsphere.ai/blog/vw4e-flutter-webrtc-ai-voice-agents-2026
category: "AI Voice Agents"
tags: ["Flutter", "flutter_webrtc", "Voice AI", "Mobile", "Pipecat"]
author: "CallSphere Team"
published: 2026-03-25T00:00:00.000Z
updated: 2026-05-07T16:13:34.642Z
---

# 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:

- **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](/industries/real-estate).
- **Healthcare** — Healthcare partner apps use the OpenAI Realtime path with HIPAA-safe payloads. See [/industries/healthcare](/industries/healthcare) and [/lp/healthcare](/lp/healthcare).
- **/demo browser path** — Same agents, plain Chrome. See [/demo](/demo).

37 agents · 90+ tools · 115+ DB tables · 6 verticals · HIPAA + SOC 2 · $149/$499/$1499 · 14-day [/trial](/trial) · 22% affiliate at [/affiliate](/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
}
```

```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

- [https://pub.dev/packages/flutter_webrtc](https://pub.dev/packages/flutter_webrtc)
- [https://github.com/flutter-webrtc/callkeep](https://github.com/flutter-webrtc/callkeep)
- [https://medium.com/@tri.dev.dhm/building-real-time-voice-ai-agents-in-flutter-with-pipecat-6abbc6d223f0](https://medium.com/@tri.dev.dhm/building-real-time-voice-ai-agents-in-flutter-with-pipecat-6abbc6d223f0)
- [https://getstream.io/video/sdk/flutter/tutorial/ai-voice-assistant/](https://getstream.io/video/sdk/flutter/tutorial/ai-voice-assistant/)
- [https://github.com/livekit/agents](https://github.com/livekit/agents)

Try CallSphere voice agents at [/demo](/demo), see [/pricing](/pricing), or start a [/trial](/trial).

---

Source: https://callsphere.ai/blog/vw4e-flutter-webrtc-ai-voice-agents-2026
