Back to Windows Tips
FFmpeg
ffmpeg.org

FFmpeg is the Swiss Army knife of video and audio processing. It can convert, compress, trim, merge, stream, and analyse virtually any media format. It runs entirely on the command line and is used behind the scenes by VLC, Chrome, and most video software.

winget install Gyan.FFmpeg
  • Supports virtually every video and audio codec and container format
  • Hardware-accelerated encoding via NVENC, QuickSync, AMF
  • Complex filter graph for overlay, scale, crop, and subtitle burn-in
  • Used internally by yt-dlp to merge separate video and audio streams
# Convert between formats (auto-detects codec from extension)
ffmpeg -i input.mkv output.mp4

# Extract audio track as MP3
ffmpeg -i input.mp4 -vn -acodec libmp3lame output.mp3

# Compress video (higher CRF = smaller file, lower quality)
ffmpeg -i input.mp4 -crf 28 output.mp4

# Trim: start at 1:00, cut 2 minutes (no re-encode)
ffmpeg -i input.mp4 -ss 00:01:00 -t 00:02:00 -c copy out.mp4

# Merge separate video and audio files
ffmpeg -i video.mp4 -i audio.m4a -c copy output.mp4

# Create an animated GIF from a video clip
ffmpeg -i input.mp4 -vf "fps=15,scale=640:-1" output.gif

# Scale video to 1920x1080
ffmpeg -i input.mp4 -vf "scale=1920:1080" output.mp4

Comments

Sign in with GitHub to leave a comment or reaction.