Key takeaways
- Sample rate counts sample frames per second; compressed bitrate counts encoded bits per second.
- For packed PCM, rate × stored bits per sample × channels gives the sample-payload bitrate.
- A larger output cannot restore detail that a recording or earlier lossy encode discarded.
A 48 kHz recording and a 128 kb/s recording tell you different things about a file. Sample rate counts samples over time, bit depth describes how precisely samples are stored, channels carry separate signals, and bitrate measures data per second. Here is how those properties work together when you convert audio or estimate its size.
Inspect the signal representation before choosing an output
Start by probing the file. WAV commonly contains PCM, but it can hold other encodings; MP4 can hold audio with or without video. Record the codec, sample rate, sample format, channel count, channel layout, and duration. You will need these values to choose a conversion and compare the output with the source.
A probe is also a way to expose uncertainty. An absent channel layout is different from a known stereo layout. For PCM, inspect the codec and bits_per_sample or bits_per_raw_sample for stored precision: 24-bit PCM can decode into sample_fmt: "s32", which does not make its stored samples 32 bits wide. An absent or zero precision field is not a reason to guess. The command below inspects metadata without modifying the source.
ffprobe -v error -select_streams a:0 \
-show_entries stream=codec_name,sample_rate,sample_fmt,channels,channel_layout,bits_per_sample,bits_per_raw_sample:format=duration,size,bit_rate \
-of json input.wavUse sample rate to describe the time grid
Sample rate counts the sample frames representing a second of audio. At 48 kHz, every channel contributes 48,000 samples per second. Stereo adds a second simultaneous value to each frame rather than doubling the frame rate. This distinction matters when reading APIs that expose buffer length in frames and when estimating how many values a decoder places in memory.
The recoverable frequency band must stay below half the sample rate, the Nyquist frequency. Before sampling or downsampling, low-pass filtering removes higher-frequency content so it does not fold back into false lower-frequency signals. Real filters need space to roll off, so the usable band ends below that limit. A 96 kHz conversion of a 44.1 kHz source cannot acquire information absent from its input; choose a supported delivery rate.
Keep sample precision separate from compressed bitrate
For integer PCM, bit depth determines how many levels can represent each sample. Sixteen bits provide 65,536 possible integer values; twenty-four bits provide more values over the same nominal range. Floating-point formats divide their bits differently, so “32-bit float” does not mean 32 bits of uniform integer precision. Check which sample format each processing tool expects.
Compressed bitrate is instead the rate of encoded data. An Opus stream at a chosen target bitrate uses a codec model to represent the signal within that budget. A 128 kb/s target is an encoded data rate; it does not describe bit depth. Encoder implementation, signal content, channels, and operating mode affect the audible result. Compare the actual output, especially with difficult transients, noise, and quiet speech.
Calculate uncompressed size from a concrete example
Consider one minute of packed, 16-bit stereo PCM at 48 kHz. Multiply 48,000 sample frames per second by two samples per frame and sixteen bits per sample. The payload is 1,536,000 bits per second, or 192,000 bytes per second. Over sixty seconds that is 11,520,000 bytes: 11.52 decimal MB, roughly 10.99 MiB, before the container adds headers and metadata.
This formula applies to the stored sample width, not every arbitrary “bit depth” label. A representation can use padding, and compressed formats do not follow the same fixed payload rule. For a constant 128,000-bit-per-second encoded payload, sixty seconds gives about 960,000 bytes before overhead. Variable bitrate, embedded artwork, and stream/container framing can change the real file size, so inspect the produced artifact.
One change at a time
Keeping rate and duration fixed while reducing stereo to mono halves packed PCM sample data. Whether that downmix is acceptable depends on the recording’s contents, not the arithmetic alone.
Payload versus file
The calculation predicts audio sample bytes. A large embedded cover image can make a short audio file substantially larger without changing its sample rate or audible signal.
Choose channels according to their meaning
Audio channels can represent spatial positions or separate microphones. An interview with the host on the left and guest on the right needs different treatment from a stereo music mix, even though both have two channels. Listen before selecting or combining channels. Keeping only one channel of that interview would lose a speaker; selecting the wrong surround channel could lose the dialogue.
Downmixing requires a rule for combining signals, and opposite-polarity content can cancel. A mono output that looks valid in a probe can therefore be missing important material. Keep the source and review a representative passage after conversion. If channel identity is uncertain, obtain or establish that mapping before publishing a batch under a guessed layout.
Convert deliberately and verify the complete deliverable
Treat resampling, changing sample precision, mixing channels, and encoding as distinct choices even if one tool performs all of them. Keep a suitable lossless master and create the delivery representation from that master. Repeated lossy exports can add degradation, and converting a lossy source to a larger lossless file only preserves the decoded result you already have.
After conversion, re-probe the output and verify duration, rate, channels, codec, and container. Listen to quiet and loud passages, transitions, stereo placement, and difficult names or consonants. Compare at matched listening levels so a louder version does not win simply because it is louder. Finally, test playback in the intended browser or device: a codec name and a file extension are only part of compatibility.
Technical details worth knowing
- At 48 kHz, stereo audio has 48,000 sample frames per second and two simultaneous samples in every frame.
- For 16-bit packed stereo PCM at 48 kHz, the sample payload is 1,536,000 bits per second before container overhead.
- A higher sample rate permits a wider representable frequency band, but resampling cannot recover absent source frequencies.
- Integer bit depth describes quantization precision; floating-point formats have a different distribution of precision and range.
- Lossy codec bitrate is an encoder policy, and variable-bitrate output does not necessarily have the requested bitrate at every moment.
- WAV is a container and commonly stores PCM; the filename extension alone does not establish its internal sample encoding.
A practical approach
- 1
Probe the input’s actual codec, sample rate, sample format, channel count, and layout.
- 2
Choose the destination’s required representation and preserve a suitable source master.
- 3
Convert once using deliberate sample-rate, channel, codec, and bitrate settings.
- 4
Inspect the resulting metadata, verify duration, and listen on the target playback path.
When Transloadit is useful
Transloadit’s Audio Encode Robot offers presets and audio settings for creating delivery files. Choose a preset for the required format, then check its sample rate, bitrate, and channel settings against the file you need.
Architecture boundary
File properties and size calculations cannot tell you how a recording sounds. Listen after downmixing or lossy encoding, and test the result in the player your audience will use.
Frequently asked questions
Is 48 kHz better than 44.1 kHz?
Neither number alone establishes audible quality. They define different sample grids and representable bands. Use the rate required by the workflow or player, and evaluate the source, filtering, codec, and listening context together.
Does converting MP3 to WAV improve the original quality?
It can provide a convenient uncompressed representation for further work, but it cannot restore information discarded by the MP3 encoder. Preserve a lossless source before delivery encoding when future revisions are expected.
Why is my stereo buffer twice as large as mono?
At the same duration, frame rate, and sample representation, stereo carries two simultaneous samples per frame while mono carries one. That doubles packed PCM sample data; compressed-file size depends on additional codec decisions.
Can I predict a compressed file’s exact size from its sample rate?
No. Sample rate is not compressed bitrate. You also need the codec’s rate-control behavior, duration, container overhead, and metadata. Measure the encoded file when an exact upload or delivery limit matters.