Browser FFmpeg recipe

Reduce Video File Size Online with FFmpeg

Downscale and compress a video for a much smaller output file.

Command

Run this FFmpeg command

ffmpeg -i input.mp4 -vf scale=1280:-2 -c:v libx264 -crf 30 -preset fast -c:a aac -b:a 96k smaller.mp4

When to use it

  • large phone videos
  • support uploads
  • social previews

How it works

  1. Upload the video file.
  2. Run the command to downscale to 1280px wide and compress with H.264.
  3. Download the smaller MP4 file.

Option reference

OptionWhat it does
scale=1280:-2Sets width to 1280px and keeps a valid even height.
-crf 30Uses stronger compression than the default recipe.
-b:a 96kUses compact audio for smaller output.

Practical notes

  • Use 1920 instead of 1280 if you need a larger HD result.
  • If text becomes blurry, lower CRF to 24 or 26.

FAQ

How do I make the output even smaller?

Use a smaller scale width such as 960 and a higher CRF value such as 32.

Why does FFmpeg use -2 for height?

It keeps the aspect ratio and chooses an even height, which avoids codec errors.