

ffmpeg -i input.mp4 -vcodec h264 -b:v 200k -an output.Update 2020: This answer was written in 2009.ffmpeg -i input.mp4 -vcodec h264 -b:v 1000k -an output.mp4.Good enough worked fine for me.To my "average human" eye, i coudlnt find any real difference with the original video compared side by side (original: 1gb to good enough: 296mb)Įdit: if you wanna go lower try changinng -b:v value e.g.: ffmpeg -i input.mp4 -vcodec h264 -b:v 700k -acodec mp3 output.mp4 and if you don't want sound try: ffmpeg -i input.mp4 -vcodec h264 -b:v 700k -an output.mp4



if the output is not enough then use 2/3 of the original video bitrate with -b:v and keep lowering until you reach a desired size.I'd recommend that you first let ffmpeg compress it automatically without any arguments ffmpeg -i input.ext output.mp4 not all videos will look good with a video bitrate of 700kb it depends on the resolution, the original codec used and whether there's a lot of movement / particles.for audio it's better to specify the bitrate rather than the codec, 96Kb is good enough -b:a 96k.in the time of writing this (jan 2023) you don't need to specify h264 as the video codec in ffmpeg when the output is mp4 since that's the default codec.
