Skip to main content

Common Output Options

General FFmpeg Usage

6. Common Output Options

OptionDescription
-c:vVideo encoder; copy copies the stream directly
-c:aAudio encoder
-b:v / -b:aTarget video or audio bitrate
-maxrateMaximum video bitrate constraint
-bufsizeRate-control buffer size
-rOutput frame rate
-gGOP length, or keyframe interval
-pix_fmtOutput pixel format
-arAudio sample rate
-acNumber of audio channels
-movflags +faststartMove the MP4 index to the beginning for progressive web playback

Create an MP4 suitable for web playback:

ffmpeg \
-i input.mp4 \
-c:v libx264 \
-crf 23 \
-c:a aac \
-movflags +faststart \
output-web.mp4