Music streaming services often advertise their product by highlighting that they have a (more expensive of course) option for uncompressed or Studio Quality audio, because it supposedly sounds much better than compressed MP3 files. Uncompressed just sounds better, it's clearer, has more dynamic range, more depth, better high end and so on, is how the story goes. Frankly, I think this is mostly nonsense. MP3s at high bitrates can be considered transparent (more on this below), which means they sound indistinguishable from the original uncompressed sound source. At lower bitrates, sure, they sound worse. A 128kbit/s stereo MP3 file that you downloaded from Napster in 1999 will definitely sound worse than the uncompressed original recording that it was created from. But modern MP3 encoders are much better than those from the past, and at a bitrate of 320kbit/s they deliver audio quality that in my opinion very few people will be able to tell apart from the uncompressed original.
Any difference between compressed and uncompressed on streaming is more likely the result of the streaming service either not processing the MP3s with the highest possible bitrate despite saying so, or doing some other shenanigans to make the uncompressed audio sound better than the MP3s. They might simply make the uncompressed versions a little bit louder than the compressed ones. Our ears equate louder with better (this is why the music in clubs and at rock concerts is so insanely loud), and so if I play you the exact same recording twice, but once at a slightly higher volume, you will perceive the louder one as sounding better, even though they are completely identical. And of course the placebo effect is strong; if I pay more for uncompressed audio with higher fidelity and more bits and more kHz and whatnot, certainly it has to sound better! That alone might be enough to colour my opinion.
But - maybe I'm wrong here? Maybe 320kbit/s MP3s really do sound worse than an uncompressed audio file?
Luckily, there is an easy way to figure it out. All I need is some uncompressed audio, then compress it to MP3 and then compare the two and see which one sounds better. So that's what I did, and because I like talking about tech stuff, I thought I'd put it online here for you to test, too.
What is compression anyway?
I don't want to dive too deep into the theory here because I could write a whole series about this topic, but I thought I'd at least quickly mention what compressed and uncompressed audio even means. Feel free to skip this if you're not interested in the technical details.
An uncompressed or lossless audio file means that the waveform of the original recording is digitised with an analogue to digital converter and stored as a series of digital values. Very roughly it works like this: Audio is recorded with a microphone, which turns sound waves (which are changes in air pressure) into changes in electric voltage in a wire. This is called an analogue audio signal. Converting it to digital means looking at this signal in regular intervals and writing down which value the voltage has at this moment. That's it. For CD quality audio the looking at the signal (called sampling the signal) is performed 44.100 times per second, and the voltage values are written as 16 bit numbers, which allows us to differentiate 2^16 = 65536 individual voltage values). This is fine enough granularity to cover the entire range of frequencies that our ears can perceive (20Hz - 20.000Hz) with very high fidelity.
Lossy audio compression means that this digital representation of the original audio recording is now analysed and split up into it's individual frequencies. Frequencies which our ears cannot perceive are then removed from the signal, which reduces the amount of information the signal contains and therefore reduces the filesize. For example, if our recording contains at one point a loud bang on the snare drum and a very quite guitar note which is played at the same time, then our ears cannot hear the quiet note while the loud sound is playing because the loud sound simply drowns it out. This is called masking. The loud noise masks the quiet one. So the frequencies of the quiet notes can be removed without altering the sound to our ears, because we wouldn't have heard it anyway. If this is done carefully and not too much information is removed, the compressed audio file should sound virtually indistinguishable to us from the uncompressed file. If the compression is too aggressive, it will also remove frequencies which we would have heard, resulting in weird distortions in the sound, which is called compression artefacts.
The level of compression is typically give as the number of how many bits of information the compressed audio signal is allowed to use for every second of audio. One second of uncompressed stereo music in CD quality (44.100Hz sample rate, 16 bit resolution, two channels) uses 44.100 * 16 * 2 = 1.411.200 bits or 1411kbit/s.
A 320kbit/s MP3 file will remove as much information from the audio recording as is necessary to squeeze the remaining audio into 320kbit/s, which means it compresses the original audio recording by a factor of around 4.5 (1411kbit/s / 320kbit/s). This is generally considered transparent compression, meaning it should be indistinguishable from the original recording (this article about audio quality from the Audacity website considers even MP3 at bitrates of 170-210kbit/s as transparent).
MP3 and AAC are examples of compressed or lossy audio codecs, which remove information, FLAC and WAV are examples of uncompressed or lossless audio codecs, which don't remove information. (What's a codec? Encoder and decoder. A piece of software that stores audio to a file in a given format and reads it back.)
As a rule of thumb, what we get on a CD is uncompressed, what we get through streaming services and on YouTube is compressed (unless your streaming service offers lossless audio).
The listening test
I grabbed a few CDs off the shelf and ripped a couple of songs which I feel offer some variety to see how the MP3 codec performs. I chose to take music from my own CDs instead of downloading something so I could be sure that I'm really dealing with uncompressed audio files to begin with. Then I converted each WAV file to 320kbit/s MP3 with the lame MP3 encoder with this command:
ffmpeg -i file.wav -codec:a libmp3lame -b:a 320k file.mp3
Then I stole used in accordance with the license the amazing AB-Audio-Player code from this Github project to create the A/B test for this website. And now we can hear for ourselves which one sounds better.
Oh, one thing. If you're listening through Bluetooth headphones, you will never hear the uncompressed audio. Bluetooth always uses lossy audio compression codecs, unless you have very new and expensive headphones with aptX Lossless. But everything else, your standard Apple Airpods or Sony/Bose headphones? They all use lossy compression. You need to listen through wired headphones. (And if someone waxes poetic about how they only listen to uncompressed audio and then proceeds to stick a pair of Airpods in their ears, you now know that they have no idea what they're talking about.)
Rush - YYZ
Solution
A is WAV, B is MP3Gamma Ray - Rebellion in Dreamland
Solution
A is MP3, B is WAVEnnio Morricone - The Good, The Bad, The Ugly
Solution
A is WAV, B is MP3Queensryche - Silent Lucidity
Solution
A is MP3, B is WAVVangelis - Tears in Rain (Blade Runner OST)
Solution
A is MP3, B is WAVSo, how did you do?
I have to be honest, I don't hear a difference. I listened with good headphones (Beyerdynamic DT 880 Pro) through a Focusrite audio interface, but no matter how hard I tried to find any artefacts in the vocals, the high frequencies, the reverb etc., I just don't hear anything. And that's despite knowing which file is which. To me they sound identical and the MP3s sound completely transparent.
Of course this is in no way a comprehensive test. These are just five examples, and even if you just blindly guessed without even listening to anything, there's still a 1/32 chance that you got everything right by pure luck.
But this is also not meant to trick anyone or prove that I'm right and you're wrong or anything like this. I wanted to see if I can tell the difference between compressed and uncompressed audio, and I thought I'd take you along for the ride. I can say with confidence that despite being a musician and having studied this stuff back in University and therefore knowing what to listen for, I can't tell the difference. This is also not the first time I'm comparing compressed to uncompressed, I've done this many times in the past and I've always come to the same conclusion: To me, MP3 at high bitrates sounds on par with uncompressed audio. I can't hear a difference. Unless a streaming service is actively making the MP3s sound worse to promote their HiFi option (which I can totally see them doing), paying extra for uncompressed is simply not worth it.
For me.
It's a crime to exclude Suzanne Vega's Tom's Diner, which was used as a test during the development of the MP3 codec from this list, but unfortunately I don't have it on CD.
Btw, do you want to know what compression artefacts sound like? Have a listen:
This is MP3 at 56kbit/s. Do you hear this metallic noise in the high frequencies? That's what it sounds like when too much information is removed. This file is 165KByte, while the 320kbit/s MP3 from above is 940KByte and the uncompressed WAV is 4.1MByte.
