Configure libx265 Tier Parameter in FFmpeg
This article explains how to configure the tier
parameter when encoding video using the libx265 encoder in
FFmpeg. You will learn what the tier parameter is, the difference
between the “main” and “high” tiers in the HEVC/H.265 standard, and the
exact FFmpeg commands required to set this parameter for your video
compression workflows.
What is the Tier Parameter in HEVC?
In the HEVC (H.265) video compression standard, tiers and levels define the limits on hardware decoding capabilities, such as maximum bitrate, resolution, and frame rate.
While Levels (e.g., 4.0, 5.0, 5.1) restrict the maximum sample rate and resolution, Tiers specify the maximum bitrate. HEVC defines two tiers: * main: Designed for standard consumer applications, mobile devices, and typical streaming where bitrates are relatively low. This is the default setting. * high: Designed for demanding applications, professional broadcasting, or high-bitrate archival where the limits of the main tier are insufficient.
How to Configure the Tier in FFmpeg
You can configure the tier parameter in FFmpeg using two different
methods: using the direct FFmpeg -tier option, or passing
it as a private option inside the -x265-params
argument.
Method 1: Using the
-tier Flag
The most straightforward way is to use the native FFmpeg option. You
can set this to either main or high.
To set the tier to high:
ffmpeg -i input.mp4 -c:v libx265 -tier high output.mp4To set the tier to main:
ffmpeg -i input.mp4 -c:v libx265 -tier main output.mp4Method 2: Using the
-x265-params Flag
Alternatively, you can pass the parameter directly to the underlying
libx265 library using the -x265-params option.
This method is highly reliable across different versions of FFmpeg.
To set the tier to high via x265 params:
ffmpeg -i input.mp4 -c:v libx265 -x265-params tier=high output.mp4If you are passing multiple parameters, separate them with a colon:
ffmpeg -i input.mp4 -c:v libx265 -x265-params tier=high:level-idc=5.1 output.mp4When to Use Main vs. High Tier
- Use Main Tier for maximum compatibility. Most consumer playback devices (smart TVs, older smartphones, and streaming boxes) only support the main tier.
- Use High Tier when you are encoding high-resolution content (like 4K or 8K) at very high bitrates that exceed the limits of the main tier for your selected level. Be aware that high-tier files may fail to play on older or budget-friendly hardware decoders.