Overview
yt-dlp can convert downloaded media to different formats using ffmpeg. This includes remuxing (changing container without re-encoding) and transcoding (re-encoding to a different codec).Remuxing Videos
Remux changes the container format without re-encoding the video/audio streams:Supported container formats
- Video:
mp4,mkv,webm,flv,avi,mov,gif - Audio:
m4a,aac,mp3,opus,ogg,flac,wav,alac,mka,aiff
Conditional Remuxing
Use rules to remux specific formats:Re-encoding Videos
Transcode videos to different codecs:Audio Format Conversion
Extract and convert audio
1
Basic extraction
2
Convert to specific format
3
Set audio quality
Conditional audio conversion
Format Selection with Conversion
Combine format selection with conversion for precise control:Preset Format Conversions
yt-dlp includes useful presets:MP4 Preset
- Sets output to MP4 container
- Prefers H.264 video codec
- Prefers AAC audio codec
- Optimizes for compatibility
MKV Preset
Converting Existing Files
Convert already downloaded videos:1
Download metadata
2
Re-process the file
Subtitle Format Conversion
Convert subtitle formats:Thumbnail Format Conversion
Convert thumbnail images:Advanced Conversion Scenarios
Encode for specific devices
Compress video
Convert with custom ffmpeg options
Merge Multiple Streams
Merge video and audio while converting:Merge with multiple audio tracks
Fixup Options
Automatically fix common format issues:Common Conversion Workflows
Maximum compatibility
Archival quality
Space-efficient
Audio for music players
Troubleshooting
Conversion fails
Container doesn’t support codec
Quality loss
Next Steps
Post-Processing
Learn about all post-processing options
Audio Extraction
Detailed audio extraction guide
Format Selection
Advanced format selection reference
Post-Processor Arguments
ffmpeg and post-processor arguments