Skip to main content

View a Stream

Play video streams using manifest URLs.

What is a Manifest Player?​

A Manifest Player plays video streams using manifest URLs (HLS .m3u8, FLV .flv, or DASH .mpd) rather than connecting directly to a WebRTC call. This is commonly used for:

  • Transcoded broadcasts with multiple quality levels
  • Archived/recorded streams (VOD - Video on Demand)
  • CDN-delivered content
  • Scenarios where ultra-low latency isn't required

A Manifest Player plays video streams using a manifest URL (HLS .m3u8, FLV .flv, or DASH .mpd) rather than connecting directly to a WebRTC call. This is commonly used for:

  • Transcoded broadcasts with multiple quality levels
  • Archived/recorded streams (VOD)
  • CDN-delivered content
  • Scenarios where ultra-low latency isn't required

Codec Support and the Snapshot Fallback​

All live browser formats are encoded as H.264 video with AAC audio — there are no VP9 or AV1 live renditions. Every mainstream browser plays H.264, so this rarely matters in practice, but on a browser or device without H.264 support the player has no playable format.

When that happens the player degrades gracefully and automatically: it emits noDrivers, and shows the stream's live snapshot image as a poster, refreshed on the manifest polling interval — so the viewer still sees a periodically-updating picture of the live stream. This requires nothing from your client code:

  • The manifest carries a jpeg format (formats.jpeg.encodings[] at several resolutions) and a previewImg URL; the player picks the best fit and sets it as the video poster (displayPoster option, on by default).
  • The images come from the platform's snapshot service, so they are only available while the stream is live and producing snapshots.

Subscribe to noDrivers and the manifest event (see Player Events & Liveness) if you want to detect this state and adjust your UI.

Each tab below hands the player a manifestUrl. Get it from the stream-detail response: the manifestUrl field is a complete URL ending in <streamId>.json — treat it as opaque and pass it to the playback SDK verbatim, never constructing or modifying it yourself. The same response also carries vfManifestUrl, the video-foundation manifest for that stream; this guide uses manifestUrl only. See Manifests.

Player components​

The React Native SDK, @video/react-native-sdk, ships two player components. Both take the manifestUrl from the stream-detail response and a session from getSession. Install the SDK and its pinned peer packages first, as described in the React Native tab of Installation.

VideoPlayer​

VideoPlayer plays HLS only, with no WebRTC path, and adds live DVR: it switches between live and DVR modes on its own, and its ref exposes rewind, seekTo, goLive, and refetch. Use it when you want dependable HLS playback and the extra latency of HLS is acceptable.

import React, { useRef } from 'react';
import { View, Button } from 'react-native';
import { VideoPlayer, VideoPlayerMethods, getSession } from '@video/react-native-sdk';

export default function HlsPlayer({ manifestUrl }: { manifestUrl: string }) {
const videoRef = useRef<VideoPlayerMethods>(null);
const session = getSession({
backendEndpoint: '<your backend endpoint>',
displayName: 'Viewer',
streamName: 'viewer',
});

return (
<View style={{ flex: 1 }}>
<VideoPlayer
ref={videoRef}
manifestUrl={manifestUrl}
session={session}
autoplay
style={{ width: '100%', height: 200 }}
onLoad={() => console.log('Video loaded')}
onError={(error) => console.error('Video error:', error)}
/>
<View style={{ flexDirection: 'row', justifyContent: 'space-around', marginTop: 10 }}>
<Button title="Rewind 10s" onPress={() => videoRef.current?.rewind(10)} />
<Button title="Go live" onPress={() => videoRef.current?.goLive()} />
</View>
</View>
);
}

ManifestPlayer​

ManifestPlayer plays WebRTC and falls back to HLS on its own. It is a render-prop component: it hands you the manifestPlayer instance and you draw it with ManifestPlayerVideo, which renders the video and, when you ask for them, play/pause and quality controls.

import React from 'react';
import { ManifestPlayer, ManifestPlayerVideo, getSession } from '@video/react-native-sdk';

export default function LowLatencyPlayer({ manifestUrl }: { manifestUrl: string }) {
const session = getSession({
backendEndpoint: '<your backend endpoint>',
displayName: 'Viewer',
streamName: 'viewer',
});

return (
<ManifestPlayer manifestUrl={manifestUrl} session={session} autoplay muted={false}>
{({ manifestPlayer }) => (
<ManifestPlayerVideo manifestPlayer={manifestPlayer} showControls showQualitySelect />
)}
</ManifestPlayer>
);
}

To overlay your own UI on the video, swap ManifestPlayerVideo for ManifestPlayerVideoCustomControls and pass your controls as children.

Choosing a player​

  • Use VideoPlayer for HLS-only playback with DVR controls and the lower overhead of a single driver.
  • Use ManifestPlayer when viewers need WebRTC latency and you want the SDK to fall back to HLS without extra code.

Component reference​

VideoPlayer props​

PropTypeDefaultDescription
manifestUrlstring-Required. Manifest URL for streaming
sessionSession-Required. User session for authentication
autoplaybooleanfalseStart playback automatically when ready
mutedbooleanfalseStart with audio muted
preferredScoreLevelTranscodeScoreLevel | SourceScoreLevel-Preferred quality level
videoClientOptionsVideoClientOptions-Additional video client configuration options
debounceInitTimenumber500Debounce time for initialization in milliseconds
delegateVideoPlayerDelegate-Delegate for handling player events
styleViewStyle-Style object for the video container
childrenReactNode-Custom UI elements to overlay on the video
keystring | number-React key prop
progressUpdateIntervalnumber-Progress updates interval in milliseconds
resizeModeResizeMode-Video resize mode (contain, cover, stretch)
preventsDisplaySleepDuringVideoPlaybackbooleantruePrevents the device screen sleeping during playback
allowsExternalPlaybackbooleantrueAllows video to be played on external devices
pausedbooleanfalseControls video playback state
ratenumber1.0Playback speed rate
onProgressfunction-Callback for playback progress updates
onLoadfunction-Callback called when the video loads
onEndfunction-Callback called when the video ends
onErrorfunction-Callback called on a video error
onFullscreenPlayerDidDismissfunction-Callback when the fullscreen player is dismissed
onPlaybackStateChangedfunction-Callback when the playback state changes
onLiveDvrStateChangefunction-Callback when transitioning between live and DVR modes
refRefObject<VideoPlayerMethods>-Ref object for the methods below

The VideoPlayer ref exposes four methods:

rewind(seconds: number): void;
seekTo(seek: number): void;
goLive(): void;
refetch(): void;

ManifestPlayer props​

PropTypeDefaultDescription
manifestUrlstring-Required. Manifest URL for streaming
sessionSession-Required. User session for authentication
players('webrtc' | 'native-hls')[][{ id: 'webrtc' }]Array of player drivers to use
autoplaybooleanfalseStart playback automatically when ready
mutedbooleanfalseStart with audio muted
preferredScoreLevelTranscodeScoreLevel | SourceScoreLevel-Preferred quality level
videoClientOptionsVideoClientOptions-Additional video client configuration options
debounceInitTimenumber500Debounce time for initialization in milliseconds
delegateManifestPlayerDelegate-Delegate for handling player events
childrenfunction-Render prop receiving the manifestPlayer instance

ManifestPlayerVideo props​

PropTypeDefaultDescription
manifestPlayerManifestPlayer-Required. Player instance from the render prop
styleViewStyle-Style object for the video container
showControlsbooleanfalseShow play/pause/refresh controls (WebRTC only)
showDriverbooleanfalseShow the current driver
showQualitySelectbooleanfalseShow the quality selection dropdown

ManifestPlayerVideoCustomControls props​

PropTypeDefaultDescription
manifestPlayerManifestPlayer-Required. Player instance from the render prop
styleViewStyle-Style object for the video container
keystring | number-React key prop
childrenReactNode-Custom UI elements to overlay on the video
refRefObject<any>-Ref object for the video element methods
progressUpdateIntervalnumber-Progress updates interval in milliseconds
resizeModeResizeMode-Video resize mode (contain, cover, stretch)
preventsDisplaySleepDuringVideoPlaybackbooleantruePrevents the device screen sleeping during playback
allowsExternalPlaybackbooleantrueAllows video to be played on external devices
pausedbooleanfalseControls video playback state
mutedbooleanfalseStart with audio muted
ratenumber1.0Playback speed rate
onProgressfunction-Callback for playback progress updates
onLoadfunction-Callback called when the video loads
onEndfunction-Callback called when the video ends
onErrorfunction-Callback called on a video error
onFullscreenPlayerDidDismissfunction-Callback when the fullscreen player is dismissed
onPlaybackStateChangedfunction-Callback when the playback state changes

getSession​

getSession creates and returns the Session object every component takes. It accepts one options object:

ParameterTypeRequiredDescription
backendEndpointstringYesYour backend endpoint URL
displayNamestringYesDisplay name for the session
streamNamestringYesUnique stream identifier
debugbooleanNoEnable debug mode (default false)
supportWebRTCbooleanNoEnable WebRTC support (default true)

Encoder, the broadcasting component, takes a single session prop; the Quickstart React Native tab shows it in use.

Requirements and permissions​

The SDK needs React Native 0.78.0 or later, React 18.2.0 or later, iOS 15.1 or later, and Android API 24 or later. Playback needs the INTERNET permission on Android; an app that also broadcasts needs camera and microphone permissions too, as shown in the Quickstart.

If the player stays blank, check that the manifest URL is correct and reachable from the device, and that the network permission is declared. Check these first. If both are fine, check viewer authorization (see Private Stream Viewer Auth).

Key Concepts​

Player​

The Player instance manages video playback:

  • Loads and parses manifest files
  • Handles adaptive bitrate streaming (automatically switches quality based on network conditions)
  • Provides playback control methods (play(), pause(), mute(), unmute())
  • Manages audio and video state

Manifest URL​

A manifest file contains information about available video streams:

  • HLS (.m3u8): Apple's HTTP Live Streaming format, widely supported
  • DASH (.mpd): MPEG-DASH format, ISO standard for adaptive streaming
  • FLV (.flv): Flash Video format, used for low-latency streaming
  • JSON: Native Frame's multi-format manifest containing all available options

Adaptive Bitrate Streaming​

The player automatically adjusts video quality based on:

  • Available bandwidth
  • Device capabilities
  • Buffer health
  • Network conditions

This ensures smooth playback with minimal buffering.

Player Properties​

Key properties for controlling playback:

  • localVideoPaused: Check if video is paused
  • localAudioMuted: Check if audio is muted
  • localAudioVolume: Get/set volume (0-1 range)

Manifest Player vs WebRTC Player​

FeatureManifest PlayerWebRTC Player
ConnectionHLS/FLV/DASH URLsDirect to live calls
AuthenticationNone for a public manifest; a private stream passes auth: authClient (contexts manifest / manifest-headers)Required
Adaptive BitrateSupportedN/A
LatencyHigher (3-30 seconds)Ultra-low (sub-second)
Best ForVOD, CDN-delivered contentReal-time interaction

A public manifest plays with no credential. For a private stream, pass auth: authClient in the requestPlayer options — the auth client attaches your token to the manifest request (manifest context) or to its request headers (manifest-headers context), and the same option covers the WebRTC driver. See Private Viewer for the full pattern.

Next Steps​

To learn more about the video-client-core library and advanced features: