Video on Demand
Overview
In Video on Demand (VoD) streaming workflows, users access pre-recorded content on their preferred devices via the internet. Before reaching end-users, video content undergoes several key stages:
- Ingest: Transfer a high-quality, intermediate (mezzanine) file from the source (e.g., a studio) to a AWS.
- Process: Transcode the content for distribution. File-based video transcoding is a fundamental component of VoD platforms. This process involves creating multiple versions of the original content in various formats and bitrates, optimizing it for end-users' devices and network conditions.
- Store: Host the transcoded content in a location accessible to Content Delivery Networks (CDNs) via HTTP(S). This storage solution enables a pull-based retrieval system, allowing CDNs to fetch content as needed.
- Deliver: Distribute video files at scale by caching content on CDNs before delivering it to users globally over the internet. This strategy reduces latency and improves the viewing experience.

Architectural decisions
When designing a Video on Demand (VoD) streaming workflow, it's crucial to address several key questions:
Source of Video Ingestion: Identify the origin of your content. This could range from professional studios providing film, TV, or sports content, to user-generated content (UGC) from smartphones. Understanding the interface between content creators and your distribution platform is vital for initiating an efficient content ingestion workflow. For insights on ingesting video content to AWS, consider these resources:
- Uploading large objects to Amazon S3 using multipart upload and transfer acceleration
- Uploading to Amazon S3 directly from a web or mobile application
- Easily ingest data into AWS for building data lakes, archiving, and more
Delivered Video Characteristics: Define the desired output video properties such as bitrates, frame rates, video/audio codecs, and formats. This decision involves balancing processing costs, device compatibility, and the Quality of Experience (QoE) for viewers.
Video Encoding Strategy: Choose between a custom-built solution using libraries like FFmpeg, or a managed cloud service. For a managed option, consider AWS Elemental MediaConvert, a file-based transcoding service with broadcast-grade features.
Video Packaging: Decide on pre-packaging content into various streaming formats (e.g., DASH, HLS, CMAF, MSS) and storing them in a system like Amazon S3 (Simple Storage Service) for CDN delivery. However, weigh this simplicity against storage costs and the impact of format changes. Alternatively, implement Just-In-Time Packaging (JITP) using services like AWS Elemental MediaPackage.
Content Security: Protect your valuable content from piracy and unauthorized access, especially if required by content providers. Key techniques include:
- CDN-level tokenization to prevent unauthorized downloads
- Digital Rights Management (DRM) integration using SPEKE protocol for playback control
- Watermarking to trace pirated content
Content Delivery: Utilize managed CDNs like Amazon CloudFront or implement a multi-CDN strategy.. CDNs are crucial for reducing infrastructure costs and enhancing QoE through caching.
Streaming QoE Monitoring: While server-side monitoring provides basic insights, client-side monitoring offers the best QoE visibility, such as the percentage playbacks impacted by buffering events. Options include:
- Building a custom solution
- Integrating third-party SDKs (e.g., Mux, DataZoom) into your player
- Implementing Common Media Client Delivery (CMCD) to relay client-side metrics to CDN logs, like with CloudFront.
Content Monetization: Choose from subscriptions, pay-per-view, or in-stream advertising. For in-stream ads, consider integrating SCTE markers into your video stream to trigger mid-roll ads, in addition to pre-roll or post-roll ads. For more on monetization strategies, refer to this page.
How to get started?
The most common way to create VoD workflows on AWS, is to build solutions using AWS building blocks, including AWS Media Services. In the rest of this article, you can learn about reference VoD architectures on AWS. For a first hands-on experience in building simple VoD workflows using AWS Elemental MediaConvert, Amazon S3 & Amazon CloudFront, you can go through this workshop at your own pace.
If you prefer procuring a fully managed VoD workflow, you can get started with one of AWS partners, such as Insys and Nomad.
In certain cases, you might have very specific requirements that are not met by managed services. In this case, you can build your solution from scratch using open source software and AWS core services (storage, compute, databases & networking services), as illustrated in this blog.
AWS Solutions for VoD
AWS provides ready-to-deploy solutions for VoD, OTT and UGC offerings based on AWS building blocks, including code, and configuration.
Foundational solution for web streaming
If you operate a website with simple VoD needs, such as single output streaming format, unified input types (single video and audio, one set of input resolutions) such as content for training and educational purposes, marketing videos, user-generated content (UGC) or small over-the-top (OTT) content libraries use cases, we recommend you start with the Video on Demand on AWS Foundation reference solution.
The Video on Demand on AWS Foundation solution allows automatically provision the necessary AWS services to build a scalable, distributed workflow for ingesting, storing, processing, and delivering video content on demand.

On a high-level, the solution works in the following way:
- Video Upload and Transcoding: A watch folder monitors new video uploads to an Amazon S3 source bucket. When a new video is detected, an AWS Lambda function triggers AWS Elemental MediaConvert. MediaConvert transcodes the video into various formats (HLS, DASH) with different resolutions and bitrates, using Quality-Defined Variable Bitrate (QVBR) encoding to ensure high quality with optimal file size.
- Storage and Distribution: Transcoded videos are stored in an Amazon S3 destination bucket, and distributed by Amazon CloudFront (CDN), speeding up delivery to end-users.
- Notification System: Upon job completion, Amazon EventBridge triggers a Lambda function, which sends notifications about completed jobs using an Amazon Simple Notification Service (SNS) topic, allow you to automate the publishing process.
- Monitoring: Amazon CloudWatch logs metrics about the encoding jobs for monitoring purposes.
Solution for advanced VoD offerings
If your requirements for ingest and streaming is more advanced than the first use case, for example you need to deal with different input types, process it separately (SD/HD/UHD versions, different frame rate) and/or you need to produce different encoding profiles and different output protocols. We recommend you evaluate with the Video on Demand on AWS reference solution.

Compared to the “foundation” solution mentioned above, it offers more advanced capabilities:
- Handles more outputs such as MP4, MPG, M4V, M2TS, or MOV. When video is added to the source Amazon S3 bucket, a Lambda function invokes the ingest workflow on AWS Step Functions instead of a one-off Lambda execution.
- During ingestion, source video details are added to Amazon DynamoDB. In this process, the content is also validated using MediaInfo, an open-source software that displays technical information about media files, and results are stored in DynamoDB.
- The solution uses the height and width of the source video to determine which job template to use to submit encoding jobs to MediaConvert. If you allow frame capture, the frame capture parameters are added to the job template. Then, the encoding job is created in MediaConvert and the details are stored in DynamoDB.
- After the video is encoded, MediaConvert sends a notification to Amazon CloudWatch. An Amazon CloudWatch Events rule invokes the publishing AWS Step Functions step function, which validates the outputs, and updates the DynamoDB table with the new content details.
- When the workflow is finished, Amazon SNS and/or Amazon SQS sends a publish notification based on the configuration you choose. If you choose to archive your source content, the source files are tagged to allow the Amazon S3 lifecycle policy to move files to Amazon Glacier or Amazon Deep Archive.
- Ability to use MediaPackage VOD as part of the workflow. When activated, the solution creates a separate set of MediaConvert custom templates that include H.265 MP4 and HLS. The solution also creates a packaging group in MediaPackage that is configured to ingest the MediaConvert HLS output stored in Amazon S3. MediaPackage packages the content, formatting it in response to playback requests from downstream devices. By default, this solution creates packaging configurations for HLS, DASH, MSS, and CMAF.
Resources
- Back to basics: HTTP video streaming
- Back to basics: GOPs explained
- Back to basics: Mechanisms used behind the scenes in video compression
- Back to basics: conditional access vs. digital rights management
- Resilient video encoding across multiple AWS regions
- How to get to market fast with Automated ABR encoding
- Preparing your video library for AVOD OTT
- Converting frame rates in the cloud with InSync FrameFormer and AWS Elemental MediaConvert
- Amazon CloudFront for Media
- AWS for Media & Entertainment launches a free digital learning badge for Direct-to-Consumer and Broadcast Foundations