audio duration from bitrate and file size
Audio File Duration Calculator guide
When a file can’t be opened yet, its size and average audio bitrate give a rough running time. Match the size unit to your file listing and enter the effective bitrate for the whole clip.
Play the instrument ↑- Example
- A 30 MB file at an average bitrate of 320 kbps estimates to 750 seconds, or 12.5 minutes. At 128 kbps the same file size estimates to 1,875 seconds. Thirty MiB at 320 kbps gives 786.432 seconds.
Formula and units
Duration in seconds = file bytes × 8 ÷ (kbps × 1,000). MB uses 1,000,000 bytes while MiB uses 1,048,576 bytes. A displayed file size rounded to the nearest MB can affect the estimate.
Worked examples
A 30 MB file at an average bitrate of 320 kbps estimates to 750 seconds, or 12.5 minutes. At 128 kbps the same file size estimates to 1,875 seconds. Thirty MiB at 320 kbps gives 786.432 seconds.
How to use the result
For variable-bitrate audio, use its average across the entire file. Large artwork, tags, or a container with other streams bias the result upward if all its bytes are counted as audio.
Audio Bitrate Calculator → · GestureSynth music theory tools →
Estimate a runtime before transfer or import
Suppose you have a 60 MB audio export with a measured average of 192 kbps. The estimated runtime is 2,500 seconds, or about 41.67 minutes. Double the bitrate to 384 kbps at the same size and the estimate falls to half the duration. That inverse relationship is a good sanity check when a file comes from a preset with several quality options.
Enter the exact bytes if the file manager offers them. A listing that rounds to the nearest megabyte can materially shift a short clip's estimate. At 128 kbps, one decimal megabyte represents 62.5 seconds. For an upload limit, use the same unit that the host uses. A label of “MB” usually means decimal megabytes, while some interfaces display binary quantities with ambiguous labels.
Handle variable-bitrate and container overhead
Variable-bitrate encoders can use different rates during quiet and dense portions of a recording. An average for the entire audio stream is the useful figure. A peak tells you about the highest demand during a short interval, and a target can differ from the final average. If you only have the target bitrate, treat the resulting duration as a planning estimate and compare it with the media inspector after the file becomes available.
A container might include metadata, a chapter table, cover artwork, or multiple streams. If you enter the total file size together with the bitrate of only one audio stream, the estimate can be too large. Use audio-stream bytes if your inspection tool exposes them. For a combined audio and video file, use the combined effective bitrate if you are estimating from the combined bytes.
Check decimal and binary units with a known example
At 320 kbps the audio stream consumes 40,000 bytes per second. A size of 40,000 bytes therefore represents one second under the model. At the same rate 1 MB represents 25 seconds, while 1 MiB represents 26.2144 seconds. A file shown as 30 MiB thus needs a different entry from a file shown as 30 MB, even though both labels start with the same number.
For exact editorial work, use the decoded duration or container timebase. Encoders can add priming and padding, and the intended playback length can be described by trim information. The calculator is most useful while planning storage or checking whether a file and a claimed bitrate are broadly consistent.
If your editor supplies duration and file size, calculate the implied average bitrate by dividing the total bits by the runtime. Compare the result with the encoder setting to spot cases where artwork, a second audio stream, or inaccurate file-size units may explain a discrepancy.
Answers before you play
Common questions
Can I use the peak bitrate of a variable-bitrate file?
Peak bitrate tends to make the estimated duration too short. Use the average audio bitrate or read the file’s actual duration when available.
Should I enter 0.32 for 320 kbps?
Enter 320. The bitrate field is in decimal kilobits per second. A reading of 0.32 Mbps converts to 320 kbps.
Is a zero-byte input valid?
It gives a zero-duration estimate for the mathematical model. A real audio file usually needs headers or other format information before it can be opened.
Can I estimate duration for uncompressed PCM?
Yes, if you enter the actual raw PCM bitrate and size of the audio payload. Compute the rate from sample rate, stored bits per sample, and channels if you do not have it.