03Live streaming

Live Streaming SDK wherethe audience can talk back

Hosts go live in your app and the audience reacts in real time. SDKs for Flutter and Web, so it runs in Android and iOS apps and the browser.

Interactive live streaming for your app

One host, an audience, and reactions that arrive while they still matter.

Live streams use the same real-time rooms as calls, so the audience sees the host in real time instead of watching a recording a little behind.

FlutterWeb

Fig. 03 / Host to audienceOne host streams to many viewers. Reactions and gifts come back through your app.
Host
Publishes camera and microphone.
Audience
Joins the same room to watch and react.
  • Host goes live

    The host streams camera and microphone from the app. Viewers join the same room and watch.

  • The audience reacts

    Chat, gifts and reactions run through your own app backend. Because the stream is real-time, they land while the moment is still live, and the host can answer them on air.

  • Look good live

    Hosts can use the beauty filter presets (paid plans), and your team can design custom looks in Gravix Studio.

    See the beauty filter

Live streaming SDK features

What you get when you add live streaming to your app.

  • Host and audience roles

    The token decides who can publish and who can only watch, so your server stays in charge of who goes live.

  • Real-time delivery

    Viewers join the same real-time room as the host, so chat, gifts and reactions arrive while the moment is still live.

  • Flutter and React

    The Flutter package covers Android and iOS apps; the Web SDK covers React and any browser. Hosts and viewers can mix platforms in one stream.

    Live streaming quick start
  • Chat, gifts and reactions in your backend

    Gravix Cloud carries the live audio and video. The rest runs through your own app backend.

  • Beauty filter for hosts

    Beauty filter presets on paid plans and custom Studio looks, applied before the video is sent.

    See the beauty filter

Audience and scale

What Gravix Cloud does, and what stays in your app.

  • From a few viewers to a large audience

    Tell us your expected audience size and we will confirm the right plan for it.

  • Gravix carries the stream, you keep the economy

    Gravix Cloud carries the live audio and video. Coins, gifts, payments and moderation stay in your own backend and under your rules.

Same platform as your calls

  • Tokens from your server

    Your backend signs a short-lived access token for each user. The App Certificate stays on your server and never ships inside the app.

  • A region near each person

    Each person connects through a region near them, and media takes a short route between participants.

  • Encrypted in transit

    Audio and video are encrypted in transit with DTLS-SRTP, and signalling runs over TLS.

  • Same rooms, every product

    Calls, audio rooms, live streams and AI agents all use the same rooms, tokens and SDKs. Add a product without adding a stack.

Go live in three steps

The token comes from your server, and it decides who can publish and who can only watch.

  1. 01

    Create a project

    Get your App ID and App Certificate from the Gravix Cloud console. The App Certificate stays on your server.

  2. 02

    Issue a token from your server

    Your backend signs a short-lived access token for each user and room, after your own login and checks.

  3. 03

    Join from the app

    The host joins and publishes; viewers join the same room without publishing.

  4. SDKs: Flutter, Web

    Flutter: flutter pub add gravix_rtc

    Web: npm install gravix-rtc

lib/room.dart
import 'package:gravix_rtc/gravix_rtc.dart';

final room = GravixRoomService();

// Your server signs the token. The App Certificate never ships in the app.
final tokens = GravixTokenProvider.endpoint(
  Uri.parse('https://api.example.com/rtc/token'),
  headers: {'Authorization': 'Bearer $session'},
);

// The host publishes; viewers join the same room and watch.
final joined = await room.connectWithTokenProvider(
  tokenProvider: tokens,
  request: GravixTokenRequest(room: streamId, identity: userId, name: displayName),
  publishMic: isHost,
  enableVideo: isHost,
);

room.onRemoteVideoTrack = (uid, track) => showHost(track);

Live streaming in React

The same flow with the Web SDK. See the full samples in the live streaming quick start.

host.ts
import { connectWithTokenProvider } from 'gravix-rtc';

// Host: join, then publish the camera and the microphone.
await connectWithTokenProvider(room, {
  tokenProvider: tokens,
  request: { room: streamId, identity: userId, name: userName, canPublish: true },
});
const camera = await room.localParticipant.setCameraEnabled(true);
await room.localParticipant.setMicrophoneEnabled(true);

// Your own preview: attach() returns a <video> element.
const preview = camera?.videoTrack?.attach();
if (preview) document.getElementById('stage')!.appendChild(preview);
audience.ts
import { RoomEvent, connectWithTokenProvider } from 'gravix-rtc';

const stage = document.getElementById('stage')!;

// Audience: the host's camera and mic arrive as subscribed tracks.
room
  .on(RoomEvent.TrackSubscribed, (track) => {
    stage.appendChild(track.attach()); // a <video> or <audio> element
  })
  .on(RoomEvent.TrackUnsubscribed, (track) => {
    track.detach().forEach((el) => el.remove());
  })
  // Browsers can block sound until the user clicks. Show a button, then call room.startAudio().
  .on(RoomEvent.AudioPlaybackStatusChanged, () => {
    showUnmuteButton(!room.canPlaybackAudio);
  });

await connectWithTokenProvider(room, {
  tokenProvider: tokens,
  request: { room: streamId, identity: userId, name: userName }, // canPublish defaults to false
});

Live streaming quick start: Flutter and React

Live streaming pricing

PricingFrom $1 per 2,000 minutes on Starter. Professional is $200 per 150 concurrent participants. Enterprise is $7,999 per year, terms and conditions apply.

The beauty filter is included with every paid plan. New accounts get 10,000 free minutes. See pricing

Live streaming questions

How much delay is there between the host and the audience?

Live streams run over the same real-time media as calls, so the audience sees and hears the host in real time. Try it on your own networks with the 10,000 free minutes you get when you sign up.

How do chat, gifts and reactions work?

Gravix Cloud carries the live audio and video. Chat, gifts and reactions run through your own app backend, so you keep control of payments and moderation, and because the stream is real-time they land while the moment is still live.

How many viewers can watch one stream?

Tell us your expected audience and we will confirm the right plan. Call or WhatsApp +1 650-519-1490 (US) or +880 1703-449000 (BD), or email sales@gravixcloud.com.

Which platforms can hosts and viewers use?

Gravix Cloud provides SDKs for Flutter and Web (Flutter covers Android and iOS apps).

What is a live streaming SDK?

A library you add to your app so hosts can go live and an audience can watch inside it. With Gravix Cloud the host publishes camera and microphone to a room, and viewers join the same room without publishing.

Can I build live streaming in Flutter or React?

Yes. The Flutter package covers Android and iOS apps, and the Web SDK works with React. Both use the same token flow, and the docs have a live streaming quick start with full samples for each.

Launch live streams in your app

Tell us about your hosts and your audience. Call, WhatsApp or email our team.