Download Media
Select a format to download :3 Muxed is audio+video and Video only needs a separate audio track if you plan to mux!
if a download fails try another container (MP4 vs WEBM) or a different quality :D
Combining Video & Audio (Muxing)
What is Muxing?
To provide you with the absolute highest qualities (like 1080p, 1440p, and 4K), YouTube separates the video track from the audio track. If you download a "Video Only" file, it won't have any sound.
Muxing (multiplexing) is simply stitching the separate video and audio files back together into a single playable file, without losing any quality or re-encoding.
Pro Tip: To make the commands below super easy to copy and paste, rename your downloaded files to exactly video.mp4 (or video.webm) and audio.m4a (or audio.webm) and place them in the same folder!
FFmpeg — MP4 Output
Use this when your video is MP4 and audio is M4A.
ffmpeg -i video.mp4 -i audio.m4a -c copy final.mp4
FFmpeg — WEBM Output
Use this when both tracks are WEBM.
ffmpeg -i video.webm -i audio.webm -c copy final.webm
FFmpeg — Mixed / MKV
Containers differ? (e.g. WEBM Video + M4A Audio). Use MKV format!
ffmpeg -i video.webm -i audio.m4a -c copy final.mkv
Windows Setup
1) Download FFmpeg and add it to your system PATH. 2) Place your video and audio files in the same folder. 3) Open Terminal/Command Prompt in that folder and run one of the commands above.
macOS / Linux Setup
# Install ffmpeg via Homebrew (macOS) or APT (Linux) brew install ffmpeg # macOS sudo apt install ffmpeg # Ubuntu/Debian # Navigate to your download folder and run the command!
Android (Termux)
pkg install ffmpeg cd /sdcard/Download # Then run the ffmpeg command!