DEV Community

Cover image for Eject Water From Phone Speaker
Fix My Speaker
Fix My Speaker

Posted on

Eject Water From Phone Speaker

Drop your phone in the sink, and the first problem you notice is usually the sound. Music plays, but it feels muffled, quiet, and crackly — as if the speaker is talking through a wet cloth. The good news: in many cases, nothing is broken. There is just water sitting in the speaker grill, and plain sound can push it out.

This is the simple idea behind speaker-cleaning tools, including the free one I work on. In this post, I will explain why water ruins the sound, why a low 165Hz tone fixes it, and how you can generate that tone in the browser with a few lines of JavaScript.

Why Water Makes a Phone Speaker Sound Muffled

A phone speaker is a tiny driver behind a fine mesh grill. To make sound, the speaker cone moves back and forth and pushes air. When water enters the grill, three things happen:

  • Water blocks the mesh, so air cannot move freely
  • Droplets sit on the cone, which makes it heavier and slower
  • Surface tension holds the water in place, so it does not fall out on its own

That is why shaking the phone rarely helps. The droplets are small, sticky, and trapped in a space that is only a few millimetres wide. You need something that pushes from the inside — and that something is air pressure created by the speaker itself.

The Trick: Turn the Speaker Into a Tiny Air Pump

If the speaker cone moves slowly and strongly, it works like a small pump. Each movement pushes a burst of air through the grill, and those bursts can break the surface tension and throw the droplets out. You can actually see this happen: play the right tone, and tiny drops jump off the speaker grill.

This is not a new idea. The Apple Watch has used sound to eject water from its speaker for years. Phones simply do not ship with the same feature built in, so web tools recreate it.

Why 165Hz and Not Just Any Sound?

Not every tone works well. The frequency matters a lot:

  • Very high tones move the cone only a tiny distance, so they push almost no air
  • Very low tones are weak on small phone speakers, which cannot reproduce deep bass properly
  • A low tone around 150–200Hz is the sweet spot: the cone moves far enough to pump air, and the small speaker can still play it loudly

165Hz sits right in that sweet spot. It is low enough to move a lot of air, safe for the speaker at normal listening levels, and strong enough to push water droplets out of the grill in under a minute. Many cleaning tools also sweep slowly up and down in this range, because a moving frequency can shake loose droplets that a single fixed tone misses.

Build It in the Browser: The Web Audio API

Here is the pleasant surprise for developers: you do not need an app for this. The Web Audio API, built into every modern browser, can generate a clean tone in a few lines of code:

const context = new AudioContext();
const oscillator = context.createOscillator();
const gain = context.createGain();

oscillator.type = "sine";       // a clean, smooth tone
oscillator.frequency.value = 165; // 165Hz — the water-eject sweet spot

gain.gain.value = 1;            // full volume for maximum air movement

oscillator.connect(gain);
gain.connect(context.destination);

oscillator.start();
// stop it after 60 seconds
setTimeout(() => oscillator.stop(), 60000);
Enter fullscreen mode Exit fullscreen mode

That is honestly most of the technology. A production tool adds polish on top — a frequency sweep, a timer, big touch-friendly controls, and safety warnings — but the core is just an oscillator, a gain node, and the phone's own speaker doing the physical work.

How to Use the Tone Safely

If you try this on your own phone, follow these simple steps:

  1. Remove the case and wipe the phone dry with a soft cloth
  2. Turn the volume to maximum — air movement is the whole point
  3. Hold the phone with the speaker facing down, so gravity helps the water leave
  4. Play the tone for 45–60 seconds and watch for droplets on the grill
  5. Repeat two or three times if the sound is still muffled, then let the phone air-dry

A few honest warnings:

  • Never do this with headphones connected — the tone should play from the phone speaker only
  • Do not use rice as your main plan; it does little for water already inside the grill and can leave dust behind
  • Do not charge a wet phone until the port is fully dry

What Sound Cannot Fix

Sound only removes water and loose dust from the grill area. It cannot repair a torn speaker cone, a burnt voice coil, or corrosion that has already damaged the hardware. If your speaker crackles when the phone is fully dry, distorts at low volume, or produces no sound at all after a drop, that is a repair-shop problem, not a sound problem.

Try It Yourself

If your phone speaker sounds muffled right now, you can test the idea in your browser with no install: Fix My Speaker plays the 165Hz tone (with a sweep mode) for free and works on both Android and iPhone.

And if you are a developer, the fun part is how small the core really is. A serious, genuinely useful tool can start from one oscillator node — the physics does the heavy lifting.

Top comments (0)