If you’re a commuter or listen to your music in public, there is no better upgrade you can get than noise cancelling headphones. Many people believe that in order to get better sound quality, they need to spend more, but that’s only half right: you need to also prevent noise that could overpower your music from reaching your ears. Plenty of companies have tried their hand at active noise cancelling (ANC) headphones, and a few have become so good at it that it’s one of the main selling points for their wireless headsets. But how do noise-cancelling headphones work? And why is it so cool?

Editor’s note: this article was updated on November 21, 2019 to clear up a few items.

Know thy enemy: noise

how do noise-cancelling headphones work BBC

To understand how to cancel noise, it’s important to first what sound is. If you try to visualize sound, you probably picture it in the form of a wave like the one pictured above. Though this 2D illustration will definitely come in handy later, it isn’t entirely an accurate depiction of what sound actually is. At least not until you fully understand what it implies. This is where physics kicks in.

Sound as you hear it is really just the compression and decompression of the particles in the medium in it flows through—for our purposes, we’re talking about air. It may be a little easier to picture sound as a 3D ripple through air. Those moving particles lead to very slight changes in air pressure. We call the measured power of these changes in air pressure amplitude. Your ears and brain detect and decipher those changes in pressure as sound. If you were to chart the amplitude, over time you end up with the wave pictured above. The louder the sound, the more extreme the amplitude.

How your headphones cancel outside noise

Your headphones cancel outside noise by using a trick of physics called “anti-phase.” The concept is simple, but very difficult to get right, as you’ll read ahead.

If you were to take two identical waves and place them on top of each other matching up the peaks and troughs, the two waves are said to be “in-phase” which results in an even larger wave (louder sound). But what happens if you delay one of the waves by exactly one half wavelength matching up the the troughs with the peaks of the other like in the picture below?

Constructive and Destructive Interference

The two waves are then said to be “out of phase” and subtract from one another as the positive pressures of one wave are acting against the negative pressures of the other, and vice versa. Think of it as trying to add one and subtract one. You’re just left with zero. This is the basic physics behind active noise canceling. But how is that used in your headphones?

Tiny microphones

A photo showing the microphone array of the Bose Noise Canceling Headphones 700.

The microphone array (shown here as the holes in the side) records the noise around you to calculate how to cancel it

Headphones make use of this by way of tiny microphones on the outside of your headphones. They listen to the ambient noise around you, and then the onboard electronics take it from there. The headphones then create sound that is exactly opposite to that sound wave (the anti-phase) to cancel it out so that all you should hear is the music coming from your headphones—and not anything going on outside.

Of course this is all theoretical. In practice, noise cancellation is hard to do, and far from perfect. Consistent noises like the low hums of jet engines on airplanes are easier for headphones to recognize and cancel when compared to sudden, random sounds like people talking.

While the physics remains the same, some companies are better at active noise cancelling than others. But now that you know how it works, you can pick the pair that’s right for you.

Disclosure: We may receive affiliate compensation in connection with your purchase of products via links on this page. Even though we may receive compensation, we always give our honest opinions, findings, beliefs, or experiences on each product. See our ethics policy for more details.