How to Calculate Video Bitrate and File Size
The upload form says the file is too big. You encode again, a bit smaller, and wait. It is still too big. One line of arithmetic would have told you the right bitrate before the first encode.
On this page
- The Short Answer
- File Size From Bitrate
- The Bitrate That Fits a Size Limit
- How Long a Video Fits
- MB and MiB Are Not the Same Size
- The Audio Comes Out of the Budget First
- Why the File Misses the Number
- What YouTube Recommends
- Bitrate Is Not Quality
- Related Jobs
- A Note on Privacy
- Common Questions
- Do the Sum Before the Encode
The Short Answer
A video file is its bitrate times its length. In numbers: bytes = bits per second × seconds ÷ 8. The division by 8 turns bits into bytes, because bitrates are counted in bits and file sizes in bytes.
That one sum answers three questions. How big will the file be? What bitrate fits a size limit? How long a video fits at a given bitrate? The rest of this article walks through each one, and through the three reasons a carefully sized file still comes out wrong.
Try it free: Video Bitrate Calculator – type a length, a size or a bitrate and get the other two, with the exact byte count. It takes numbers, not files: nothing is uploaded.
File Size From Bitrate
Start with the total bitrate: video plus audio. Bitrates are decimal, so 1 kbps is 1,000 bits per second and 1 Mbps is 1,000,000.
Take ten minutes of video at 8 Mbps with 128 kbps of audio. The total is 8,128,000 bits per second. Multiply by 600 seconds and divide by 8: 609,600,000 bytes, or 609.6 MB. That is the audio and video data alone. The file also holds a container – headers and an index – so the calculator keeps 3% of the file back for it by default. With that reserve the answer is about 628 MB.
The Bitrate That Fits a Size Limit
This is the question people usually have. Run the sum backwards: size in bytes × 8 ÷ seconds.
Say the limit is 10 MB and the clip is one minute long. 10,000,000 bytes is 80,000,000 bits, and over 60 seconds that is 1,333 kbps for everything. Keep 3% back for the container and you have 1,293 kbps. Take out 128 kbps of audio and the video can use about 1,165 kbps. That is the number to type into the encoder.
How Long a Video Fits
The third way round: size × 8 ÷ total bitrate gives seconds. A 4.7 GB disc at 8 Mbps of video and 384 kbps of audio holds 1:12:30 with the default reserve. All three modes use the same sum and the same reserve, so they agree with each other to the byte.
💡 Key idea
Size is fixed by bitrate and length. Resolution, codec and frame rate change how good the picture looks at that size, not the size itself.
MB and MiB Are Not the Same Size
Here is the first trap. A megabyte (MB) is 1,000,000 bytes. A mebibyte (MiB) is 1,048,576 bytes, almost 5% more. Some software shows MiB and still labels it MB.
That 5% is enough to get a file refused. A clip sized to 10 MiB is 10,485,760 bytes, and a limit of 10,000,000 bytes rejects it. When you cannot tell which unit a limit means, size to MB. It is the smaller unit, so the file fits whichever way the limit was meant. Our calculator prints the exact byte count with every answer, so you can compare it with the limit as written.
The Audio Comes Out of the Budget First
The second trap is forgetting the sound. In a small file it is a large share. 128 kbps of audio over ten minutes is 9.6 MB on its own, so a 10 MB target for a ten-minute clip leaves almost nothing for the picture.
The calculator takes the audio out before it gives you a video bitrate. If the audio alone would fill the size, it says there is no room for video instead of printing zero. A clip that does not need sound can lose its audio track and give the video the whole budget.
Why the File Misses the Number
The third trap is the encoder. A bitrate figure is an average. Encoders spend more bits on busy scenes and fewer on still ones, and how they spend them depends on the mode you pick.
- Quality modes such as CRF aim at a look, not a size. The file comes out however big that look needs.
- Target bitrate aims at the average you set. A single pass gets close.
- Two-pass reads the whole video first, then spends the bits where they are needed. It lands closest.
We tried it. A one-minute 960×540 test clip with heavy added noise, encoded with ffmpeg in two passes at 1165k of video and 128k of AAC audio, came out at 9,764,623 bytes: under the 10 MB limit, with part of the reserve to spare. The same clip at CRF 23 came out at 99 MB. Noise is the worst case for an encoder, so real footage will be less extreme, but the direction is the same.
In ffmpeg, a two-pass encode for the example above looks like this:
ffmpeg -i input.mp4 -c:v libx264 -b:v 1165k -pass 1 -an -f null /dev/null
ffmpeg -i input.mp4 -c:v libx264 -b:v 1165k -pass 2 -c:a aac -b:a 128k output.mp4
Most editors and converters have the same choice under another name: “target bitrate”, “average bitrate” or “2-pass VBR”. If a limit is strict, raise the reserve a few percent. The calculator accepts anything below 50%.
What YouTube Recommends
For uploads the question is different: not what fits, but what is enough. YouTube Help lists recommended SDR upload bitrates. As read on 1 November 2026:
- 1080p: 8 Mbps at 24 to 30 fps, 12 Mbps at 48 to 60 fps.
- 720p: 5 Mbps and 7.5 Mbps.
- 1440p: 16 Mbps and 24 Mbps.
- 2160p (4K): 35 to 45 Mbps and 53 to 68 Mbps.
YouTube calls these recommendations, not limits. The calculator has them in a list, so you can pick a row and see how big an upload at that bitrate will be.
Bitrate Is Not Quality
A higher bitrate looks better only when everything else stays the same. HEVC or AV1 can match H.264 at a lower bitrate. A talking head against a wall needs far less than a football match. Grain, noise and fast motion eat bits.
That is why our calculator gives no grade. A bitrate tells you how big the file will be. Whether it looks good at that size depends on the codec, the resolution and the footage, and only your eyes can judge that.
Related Jobs
If the clip does not need sound, Remove Audio from Video drops the track so the picture gets every bit. To keep the sound as its own file first, use Extract Audio from Video. And for a short loop with no sound at all, Video to GIF is sometimes the smaller answer.
A Note on Privacy
The calculator needs no file. You type numbers, the sum runs in your browser, and nothing is sent to a server.
Common Questions
How do I calculate video file size from bitrate?
Add the video and audio bitrates, multiply by the length in seconds and divide by 8. That gives bytes. Ten minutes at 8 Mbps of video and 128 kbps of audio is 609.6 MB of stream, before the container adds its share.
What bitrate do I need to fit a video into a size limit?
Turn the limit into bits, divide by the length in seconds, keep a little back for the container and take the audio out. For 10 MB in one minute that leaves about 1,165 kbps of video next to 128 kbps of audio.
Why is my video bigger than the calculator said?
Most often the encoder ran in a quality mode such as CRF, which does not aim at a size. Encode with a target bitrate, ideally in two passes. Also check whether the limit is in MB or MiB.
Do I have to upload my video to calculate its size?
No. The calculation needs only the length and the bitrates. Our Video Bitrate Calculator takes numbers, not files, and runs on your device.
Do the Sum Before the Encode
Encoding again and again until a file fits wastes an evening. Type the length and the limit into Video Bitrate Calculator, set the bitrate it gives you as a two-pass target, and encode once.