H.265
H.265 (also known as HEVC) is the successor to H.264, delivering roughly 40% better compression at the same visual quality. It is the codec of choice for 4K content and is well-supported across Apple devices, modern smart TVs, and streaming platforms. Transcodely uses the libx265 encoder.
Quick Start
{
"type": "mp4",
"video": [
{
"codec": "h265",
"resolution": "2160p",
"quality": "standard"
}
]
}H265Options Reference
Override defaults by passing the h265 object on a video variant:
{
"codec": "h265",
"resolution": "2160p",
"quality": "premium",
"h265": {
"profile": "main10",
"preset": "slow",
"crf": 22,
"tune": "grain"
}
}Key Differences from H.264
| Property | H.264 | H.265 |
|---|---|---|
| CRF range | 15-35 | 18-35 |
| Tune options | film, animation, grain, stillimage, fastdecode | grain, fastdecode |
| Profiles | baseline, main, high | main, main10, main-still-picture |
| Level range | 3.0-5.2 | 3.0-6.2 (8K support) |
| Encoding speed | Faster | Slower at same preset |
| Default CRF (standard) | 23 | 26 |
Presets
Same naming convention as H.264, but H.265 is generally slower at each preset level:
| Preset | Allowed | Notes |
|---|---|---|
ultrafast | Yes | Very fast, poor compression |
superfast | Yes | |
veryfast | Yes | Default for economy tier |
faster | Yes | |
fast | Yes | |
medium | Yes | Default for standard tier |
slow | Yes | Default for premium tier |
slower | Yes | |
veryslow | Not allowed | Minimal gain at extreme cost |
placebo | Not allowed |
Default by quality tier:
| Quality Tier | Default Preset | Default CRF |
|---|---|---|
economy | veryfast | 32 |
standard | medium | 26 |
premium | slow | 22 |
Profiles
| Profile | Bit Depth | Use Case |
|---|---|---|
main | 8-bit | Maximum compatibility (default) |
main10 | 10-bit | Better gradients, HDR content, higher quality at same bitrate |
main-still-picture | 8-bit | Single-frame encoding (screencasts, slideshows) |
The main10 profile is recommended for premium-tier encodes and any content that will be graded or color-corrected. It produces smoother gradients and eliminates banding artifacts common in 8-bit encoding.
Levels
H.265 extends the level system to support 8K resolution:
| Level | Max Resolution | Max Framerate | Max Bitrate |
|---|---|---|---|
3.0 | 960x540 | 30 fps | 6 Mbps |
3.1 | 1280x720 | 33 fps | 10 Mbps |
4.0 | 2048x1080 | 30 fps | 12 Mbps |
4.1 | 2048x1080 | 60 fps | 20 Mbps |
5.0 | 4096x2160 | 30 fps | 25 Mbps |
5.1 | 4096x2160 | 60 fps | 40 Mbps |
5.2 | 4096x2160 | 120 fps | 60 Mbps |
6.0 | 8192x4320 | 30 fps | 60 Mbps |
6.1 | 8192x4320 | 60 fps | 120 Mbps |
6.2 | 8192x4320 | 120 fps | 240 Mbps |
Levels are auto-selected based on resolution and framerate. Override only when targeting specific device profiles.
CRF (Constant Rate Factor)
Allowed range: 18-35 (stricter than H.264).
| CRF Range | Quality | Use Case |
|---|---|---|
| 18-20 | Near-lossless | Archival, mastering |
| 21-24 | High quality | Premium streaming |
| 25-28 | Good quality | Standard streaming (default: 26) |
| 29-32 | Acceptable | Mobile, previews |
| 33-35 | Lower quality | Low-bandwidth delivery |
H.265 CRF values are not directly comparable to H.264. An H.265 CRF of 26 produces roughly the same visual quality as an H.264 CRF of 23, at a significantly smaller file size.
Tune
H.265 supports fewer tune options than H.264:
| Tune | Best For | Effect |
|---|---|---|
grain | Film grain, vintage footage | Preserves grain texture, reduces artifacts |
fastdecode | Low-power playback | Disables computationally expensive features |
The film, animation, and stillimage tunes from H.264 are not available in H.265. The encoder handles content adaptation automatically.
Advanced Parameters
| Parameter | Range | Default | Description |
|---|---|---|---|
bitrate | 100-240,000 kbps | None (CRF mode) | Target bitrate |
maxrate | 100-240,000 kbps | None | Maximum bitrate for VBV |
bufsize | 100-480,000 kbps | None | VBV buffer size |
keyint | 1-600 frames | 250 | Maximum keyframe interval |
min_keyint | 1-60 frames | 25 | Minimum keyframe interval |
bframes | 0-16 | Per preset | B-frames between I and P |
ref | 1-16 | Per preset | Reference frames |
rc_lookahead | 0-250 | Per preset | Rate control lookahead |
aq_mode | 0-3 | 1 | Adaptive quantization mode |
aq_strength | 0.0-3.0 | 1.0 | Adaptive quantization strength |
psy_rd | "str:trellis" | Per tune | Psychovisual optimization |
Example: 4K HDR-Ready Encode
{
"codec": "h265",
"resolution": "2160p",
"quality": "premium",
"h265": {
"profile": "main10",
"preset": "slow",
"crf": 20,
"ref": 6,
"bframes": 8
}
}Example: Efficient Mobile Delivery
{
"codec": "h265",
"resolution": "720p",
"quality": "economy",
"h265": {
"profile": "main",
"crf": 30
}
}Container Compatibility
H.265 works with: MP4, MKV, MOV, TS, HLS, DASH
H.265 does not work with: WebM