Runs on your device · Your file never leaves your device.
Set the size you need and the video is encoded to fit it. This is the tool for an attachment cap, a messaging limit, or a form that refuses anything over 25 MB.
The bitrate the target allows is calculated from the video’s duration, then the result is measured and corrected if it overshoots — so you get a file that actually fits rather than one that is merely smaller.
Lowering the resolution as well as the bitrate produces a far better-looking result at small targets: a 720p video at 8 MB looks much better than the same clip kept at 1080p and starved of bitrate.
Not for: Squeezing a very long recording into a very small size — length decides how much picture fits in the megabytes; trim it first with the Trim tool.
When one video is chosen, three targets are suggested from its length, frame size, frame rate and sound. Each assumes an amount of data per pixel of picture: 0.10 bits for Nothing you can see, 0.05 for Fine for anyone, and 0.03 for Smallest that still plays, which is also brought down to 360p. For a 3-minute 1080p clip at 30 frames per second with sound, that gives 148 MB, 76 MB and 8 MB. A suggestion that would not be smaller than the file itself is marked as already this small.
3% of the target is set aside for the container. The sound gets 128 kbit/s when the target allows at least 600 kbit/s in all, less below that, down to 48; it is always encoded again as AAC. The rest goes to the picture, but never more than the original picture had. If that is too little for the frame to stay watchable, the frame steps down one standard height at a time, as far as 240 lines. For the clip above, 25 MB becomes 720p with about 950 kbit/s of picture. When even 240p would get less than 40 kbit/s, the tool refuses and names the smallest size that is still watchable.
A video already under the target is not encoded again when it is H.264, HEVC or AV1 with AAC or MP3 sound: its streams are only re-packaged as MP4.
Your device's video encoder is tried first. Its rate control tends to overshoot, so the first pass aims 5% under the calculated bitrate, and the finished file is measured. If it is over the target, the bitrate is cut in proportion, with another 5% margin, and encoded again. If it fits but uses less than 85% of the target, the bitrate is raised by up to 60% so the spare room goes to the picture. After at most three passes the largest file that fits is kept; if none fits, you get the smallest and a note saying so.
The engine runs the same loop with x264 when the device encoder cannot do the job, or when the target is over 1.5 GB, or 400 MB on a device that reports 4 GB of memory or less. On the engine, an input over 1 GB is encoded in parts, each with its exact share of the bytes and no second pass; the target then covers all the parts together.
Measured on a 4-core computer with no graphics chip, a 3-minute 1080p film compressed to 25 MB took 91 seconds on the device encoder and 653 seconds on the engine.
This page in other languages: العربية · Deutsch · Français · Español · Русский · Português · 中文 · हिन्दी · Türkçe · עברית · فارسی · اردو · Bahasa Indonesia · বাংলা