Audio File Size Calculator
Calculate audio file size from duration, sample rate, bit depth, and number of channels. Enter values for instant results with step-by-step formulas.
Calculator
Adjust values & calculateFormat Comparison
Formula
This formula calculates the raw uncompressed PCM audio size. Duration is in seconds, sample rate in Hz (samples per second), bit depth divided by 8 converts bits to bytes per sample, and channels multiplies for stereo or surround sound. Compressed formats apply a compression ratio to this base size.
Last reviewed: December 2025
Worked Examples
Example 1: CD Quality Song File Size
Example 2: Podcast Episode Storage
Background & Theory
The Audio File Size Calculator applies the following established principles and formulas. Computers represent all information using binary, a base-2 number system consisting solely of the digits 0 and 1, each called a bit. Because long binary strings are unwieldy, programmers routinely use octal (base 8) and hexadecimal (base 16) as compact shorthand. Converting between bases follows a consistent algorithm: divide the source number repeatedly by the target base, collecting remainders in reverse order. Hexadecimal digits A through F represent the values 10 through 15, allowing a single character to encode four binary bits, making it the preferred notation for memory addresses, color codes, and bytecode. Bitwise operations manipulate individual bits within integers. AND produces a 1 only when both input bits are 1, making it useful for masking. OR produces a 1 when either bit is 1 and is used for combining flags. XOR flips bits that differ, enabling simple toggle logic and efficient swap algorithms. NOT inverts every bit (one's complement), while left and right shifts multiply or divide by powers of two in constant time. Data storage units ascend in binary multiples of 1024: 8 bits form one byte, 1024 bytes form one kibibyte (KiB), 1024 KiB form one mebibyte (MiB), and so forth. Hard-drive manufacturers historically use decimal prefixes (1 KB = 1000 bytes), creating the persistent confusion between binary and decimal interpretations of the same label. The IEC standardized the binary prefixes KiB, MiB, GiB, and TiB in 1998 to resolve this ambiguity. Network bandwidth is measured in bits per second (bps), most commonly megabits per second (Mbps) or gigabits per second (Gbps). A 100 Mbps connection transfers 100 million bits every second, equating to roughly 12.5 megabytes per second. IP subnet masks define network boundaries; CIDR notation appends a prefix length (e.g., /24) to an address, indicating how many leading bits are fixed. A /24 subnet contains 256 addresses with 254 usable hosts. Algorithm efficiency is described using Big-O notation, which characterises the worst-case growth of time or space relative to input size. O(1) is constant, O(log n) is logarithmic (binary search), O(n) is linear, and O(nยฒ) is quadratic. Cryptographic hash functions like SHA-256 produce a fixed 256-bit (32-byte) digest regardless of input length. File compression algorithms exploit statistical redundancy to reduce storage footprint, and compression ratio equals the original file size divided by the compressed size.
History
The history behind the Audio File Size Calculator traces back through the following developments. The conceptual foundation of modern computing traces back to Charles Babbage, whose Analytical Engine design of 1837 introduced the idea of a general-purpose mechanical computer with separate storage and processing units, including what he called the Store and the Mill. Ada Lovelace wrote what many consider the first algorithm intended for machine execution while annotating a translation of Luigi Menabrea's account of Babbage's work, also recognising the machine's potential to manipulate symbols beyond mere numbers. George Boole published "The Laws of Thought" in 1854, formalising a two-valued algebra of logic that would later map perfectly to electrical circuits. It remained largely a mathematical curiosity until Claude Shannon's landmark 1937 master's thesis demonstrated that Boolean algebra could describe switching circuits, laying the theoretical groundwork for all digital electronics. Shannon's 1948 paper "A Mathematical Theory of Communication" defined the bit as the fundamental unit of information and established information theory as a rigorous discipline. The same year, the transistor was invented at Bell Labs by Bardeen, Brattain, and Shockley, eventually replacing vacuum tubes and enabling miniaturisation at scale. ENIAC, completed in 1945, was one of the first general-purpose electronic computers, occupying 1800 square feet and consuming 150 kilowatts of power while performing roughly 5000 additions per second. The ASCII standard was ratified in 1963, assigning 7-bit codes to 128 characters and enabling interoperability between computers from different manufacturers. Through the 1970s, the microprocessor consolidated an entire CPU onto a single chip; Intel's 4004 in 1971 marked the beginning of this trend. The Apple II launched in 1977 and the IBM PC in 1981 brought computing to homes and offices, triggering a mass-market software industry. Tim Berners-Lee proposed the World Wide Web in 1989 and launched the first website in 1991 at CERN, transforming the internet from an academic and military network into a global information infrastructure. Mobile computing accelerated through the 2000s with smartphones integrating powerful processors, wireless networking, and GPS into pocket-sized devices, extending computation into every facet of daily life and cementing TCP/IP as the universal communications fabric.
Frequently Asked Questions
Formula
Size (bytes) = Duration x Sample Rate x (Bit Depth / 8) x Channels
This formula calculates the raw uncompressed PCM audio size. Duration is in seconds, sample rate in Hz (samples per second), bit depth divided by 8 converts bits to bytes per sample, and channels multiplies for stereo or surround sound. Compressed formats apply a compression ratio to this base size.
Worked Examples
Example 1: CD Quality Song File Size
Problem: Calculate the file size of a 4-minute stereo song recorded at CD quality (44.1 kHz, 16-bit) in both WAV and MP3 320kbps formats.
Solution: WAV (uncompressed):\nSize = 240s x 44100 Hz x (16/8) bytes x 2 channels\nSize = 240 x 44100 x 2 x 2 = 42,336,000 bytes\nSize = 42,336,000 / 1,048,576 = 40.37 MB\n\nMP3 at 320 kbps:\nSize = 320,000 bits/s x 240s / 8 = 9,600,000 bytes\nSize = 9,600,000 / 1,048,576 = 9.16 MB
Result: WAV: 40.37 MB | MP3 320kbps: 9.16 MB | Compression saves 77.3%
Example 2: Podcast Episode Storage
Problem: A weekly podcast records 60-minute episodes in mono at 48 kHz, 24-bit. Calculate annual storage for raw WAV files and final MP3 128kbps exports.
Solution: Raw WAV per episode:\nSize = 3600s x 48000 Hz x (24/8) bytes x 1 channel\nSize = 3600 x 48000 x 3 x 1 = 518,400,000 bytes = 494.4 MB\n52 episodes: 494.4 x 52 = 25,708.8 MB = 25.1 GB\n\nMP3 128kbps per episode:\nSize = 128,000 x 3600 / 8 = 57,600,000 bytes = 54.9 MB\n52 episodes: 54.9 x 52 = 2,854.8 MB = 2.79 GB
Result: Annual RAW: 25.1 GB | Annual MP3: 2.79 GB | 52 episodes per year
Frequently Asked Questions
How is uncompressed audio file size calculated?
Uncompressed audio file size is calculated using the formula: Size = Duration x Sample Rate x Bit Depth / 8 x Channels. The sample rate determines how many samples per second are recorded, the bit depth determines how many bits represent each sample, and channels indicates mono or stereo. Dividing the bit depth by 8 converts bits to bytes. For example, a 3-minute stereo WAV file at CD quality (44100 Hz, 16-bit) equals 180 x 44100 x 2 x 2 = 31,752,000 bytes, or roughly 30.3 MB. This formula applies to raw PCM audio formats like WAV and AIFF, which store every single sample without any compression whatsoever.
What is sample rate and how does it affect file size?
Sample rate is the number of audio snapshots taken per second, measured in Hertz (Hz). CD quality uses 44,100 Hz (44.1 kHz), meaning 44,100 individual measurements of the sound wave every second. Higher sample rates capture more detail and higher frequencies according to the Nyquist theorem, which states that a sample rate can accurately represent frequencies up to half its value. So 44.1 kHz captures frequencies up to 22.05 kHz, which covers the full range of human hearing. Professional audio often uses 48 kHz (video standard), 88.2 kHz, 96 kHz, or even 192 kHz for archival purposes. Doubling the sample rate exactly doubles the file size, making high sample rates significantly more storage-intensive.
What is bit depth and why does it matter for audio quality?
Bit depth determines the number of possible amplitude values for each audio sample. A 16-bit audio file has 65,536 possible values per sample (2 to the 16th power), while 24-bit has over 16.7 million values. Higher bit depth provides a greater dynamic range, measured in decibels: 16-bit offers about 96 dB of dynamic range, while 24-bit provides approximately 144 dB. CD audio uses 16-bit, which is sufficient for consumer playback. Professional recording and mixing typically use 24-bit to capture quiet details and prevent clipping during production. Going from 16-bit to 24-bit increases file size by 50% (not double) because you add 8 bits to the existing 16. The 32-bit float format used in some DAWs provides even more headroom for audio processing.
What is the difference between lossy and lossless audio compression?
Lossy compression (MP3, AAC, OGG Vorbis) permanently removes audio data deemed less perceptible to human hearing, achieving dramatic size reductions of 70-90%. The original audio cannot be perfectly reconstructed from a lossy file. Lossless compression (FLAC, ALAC, WavPack) reduces file size by 40-60% without losing any audio data. When decoded, a lossless file produces bit-for-bit identical output to the original uncompressed source. Lossless formats work similarly to ZIP compression, finding patterns and redundancies in the audio data to represent it more efficiently. For archiving and audiophile listening, lossless formats preserve full quality. For portable devices and streaming with bandwidth constraints, lossy formats offer the best balance of quality and size.
How does the number of audio channels affect file size?
Each additional audio channel multiplies the file size proportionally. Mono (1 channel) produces the baseline size. Stereo (2 channels) doubles the file size because it stores separate left and right audio streams. Surround sound formats increase size further: 5.1 surround uses 6 channels (front left, center, front right, rear left, rear right, subwoofer), producing 6 times the mono file size. 7.1 surround uses 8 channels, and immersive formats like Dolby Atmos can use even more. In professional music production, multitrack recordings may contain 24, 48, or even hundreds of individual tracks, each stored as a separate channel. This is why raw recording session files can easily reach tens or hundreds of gigabytes for a single song.
What audio format should I use for different purposes?
The ideal format depends on your use case. For archival and mastering, use WAV or AIFF (uncompressed) to preserve maximum quality. For distribution while maintaining quality, FLAC or ALAC provides lossless compression at roughly half the size of WAV. For streaming services, AAC at 256 kbps is the industry standard used by Apple Music and YouTube. For podcasts and voice recordings, MP3 at 128 kbps mono is sufficient since spoken word does not require high fidelity. For web audio and game sound effects, OGG Vorbis offers good compression with wide browser support. For professional video production, use WAV at 48 kHz sample rate since that is the video industry standard sample rate for broadcast.
References
Reviewed by Daniel Agrici, Founder & Lead Developer ยท Editorial policy