Mirage CDN
Video delivery / field guide 09

HLS and DASH explained

Learn how HLS playlists and DASH manifests guide playback, how segments are cached, and what to test before delivering live or on-demand video.

By Mirage CDN · Updated

HLS and MPEG-DASH deliver media through HTTP requests. A player reads a description of a presentation, fetches the referenced media, and chooses an appropriate version as conditions change. Understanding those separate objects helps you diagnose a frozen picture without assuming every failure belongs to the delivery network. HLS overview · DASH presentation structure

For an implementation review, draw the entire path: encoder, packager, origin, cache and player. Give each stage a named owner and a test artifact. This article explains the delivery formats and proposes practical checks; it does not establish support for a particular player, codec or service configuration.

HLS uses playlists and media segments

An HLS Media Playlist is a text document listing segments with descriptive tags. A Multivariant Playlist, called a Master Playlist in RFC 8216, points to alternative streams. A player can switch among variants when network conditions change. The media may use MPEG transport streams or fragmented MP4, subject to the relevant format requirements. RFC 8216, overview and media segments

Start debugging with the playlist that the player actually requested. Inspect its response body, then resolve a referenced segment URL relative to that playlist. An HTML error page returned with a successful status is still the wrong input to a playlist parser. Keep a known-good test presentation so a manifest change can be investigated separately from a player upgrade.

DASH describes a presentation in an MPD

DASH uses an XML Media Presentation Description, usually called an MPD. It describes periods, adaptation sets and representations. Related representations can offer different encodings of the same content. Segment references and timing information tell the client which media to obtain and when it belongs on the presentation timeline. Static presentations and dynamic presentations have different availability rules; dynamic content is tied to wall-clock time. DASH-IF timing model

When inspecting an MPD, select one representation and follow it from initialization through several media segments. Check that the referenced files exist and that the time information agrees with the generated media. Repeat for a second representation before testing a switch. Save both the manifest and the failing request, because an updated live manifest may no longer describe the incident you are investigating.

Separate packaging from encoding

A codec defines how audio or video is encoded; a container organizes those encoded samples. Apple’s authoring specification lists codec and container requirements separately, including fragmented MP4 requirements for particular video formats. Treat the precise target-device requirements as part of the packaging configuration. HLS authoring specification

CMAF provides a constrained media format that can support both DASH and HLS under compatible conditions. That can allow shared media objects with different manifests, but compatibility depends on the selected constraints. It is not enough to rename files or generate a second manifest extension. DASH-IF media format guidance

Build a device matrix containing the player version, operating system, codec, audio tracks, captions and sample asset. Check the combinations your audience needs. Retain the original test outputs so an encoding change does not silently erase a previously working combination.

Give manifests and segments different cache policies

HTTP caches reuse responses according to storage and freshness rules. A fresh response can be reused when the other requirements are satisfied; no-cache instead requires successful validation before reuse, while no-store prohibits storage. These directives describe different behaviors. RFC 9111, caching directives

For your own application, classify objects before setting a policy: changing live manifests, completed manifests, versioned segments and personalized responses. Choose a freshness lifetime based on each object’s update contract. Test a manifest update while a previously fetched copy exists in the cache. Verify that the player receives the new references when your chosen policy requires it.

Avoid changing the bytes behind a long-lived segment URL. Prefer publishing a new versioned path and updating its manifest references as a coordinated release. Treat that as a deployment convention you must enforce, not an automatic property of the file extension. Review authorization and cache behavior together whenever two users can receive different content at the same URL.

Live delivery adds timing requirements

HLS live playlists can change as new segments become available. Clients reload them to discover those changes. Publication and retention must follow the protocol’s server responsibilities so advertised content remains retrievable. RFC 8216, live playlists

Low-Latency HLS adds mechanisms such as partial segments, blocking playlist reloads and preload hints. It therefore needs coordinated server and client behavior beyond serving conventional complete segments. A short segment duration alone does not demonstrate that the extension is implemented. Apple’s Low-Latency HLS overview

For a live rehearsal, record the publication time of a segment, the manifest that advertises it and the time the player requests it. Include an encoder restart and a temporary origin interruption. Document the observed recovery behavior instead of inferring it from a successful recording played after the event.

Test the HTTP and player paths together

A server can answer a valid byte-range request with 206 Partial Content and describe the returned bytes through Content-Range; a server can also ignore the range and return the complete representation. Check actual status, headers and body rather than assuming an advertised capability was used. RFC 9110, range requests

For browser playback, the DASH-IF reference implementation uses JavaScript and a browser media platform with Media Source Extensions support. A manifest opening as readable text is therefore a different check from decoding and playing its media. dash.js reference implementation

Run an uninterrupted viewing session, seek within on-demand content, change the selected audio track, and test adaptation under changing connection conditions. Keep HTTP failures, decode errors and user-visible stalls as separate observations. Ship the configuration only after the actual player and target-device combinations pass the intended viewing flow.

Sources

This guide explains technical concepts. For your delivery setup, review the documentation and request an account from our team.

Read the integration docs · Explore more CDN guides