Quick answer
Act fast: unplug the keyboard (or shut down the laptop and unplug the charger), turn it upside down to let the coffee drain, and blot the surface with a lint-free cloth. Don’t plug it back in or switch it on until it’s completely dry, which often means 24 to 48 hours. Sugar and milk leave sticky residue, so a mechanical keyboard usually needs its keycaps removed and the area cleaned with isopropyl alcohol.

In the first minute
- Cut the power. Unplug a wired keyboard. Switch off a wireless one and remove its batteries if you can. For a laptop, shut it down immediately and unplug the charger. If it won’t shut down normally, hold the power button.
- Turn it upside down. Tip the keyboard or laptop over so liquid drains out instead of soaking in. Rest a laptop open in a tent shape, keys facing down, on a towel.
- Blot, don’t wipe. Dab up visible liquid with a lint-free cloth or paper towel. Wiping spreads it.
- Don’t shake hard or use heat. Shaking can push liquid deeper, and hair dryers or ovens can damage plastics and components.
Never use a keyboard or laptop that’s still wet. Powering it on while liquid is inside can short the electronics.
Next: dry and clean it

Mechanical keyboards
Mechanical keyboards are often fixable at home.
- Pull off the keycaps around the spill with a keycap puller.
- Wash the keycaps in warm, soapy water, rinse, and let them dry fully.
- Clean the plate and switches with a cotton swab dampened (not soaked) with 90% or higher isopropyl alcohol to remove sticky residue.
- Let it dry for at least 24 hours, keys facing down.
- Test every key before refitting keycaps. If a switch feels sticky or doesn’t register on a hot-swap board, replace it.
Our guide on how to clean your keyboard covers each step, and our picks of the best keycap pullers make removing keycaps easier.
Laptops
A laptop spill can reach the motherboard and battery beneath the keyboard, so be more cautious.
- Keep it switched off, upside down, for at least 24 to 48 hours.
- Don’t try to remove laptop keys unless the maker’s instructions say you can. Scissor mechanisms break easily.
- If it was more than a few drops, or the coffee had milk or sugar, consider a professional check, even if it seems to work. Residue can cause corrosion later.
- Check your warranty or accidental damage cover before opening anything.
If keys stop working afterwards, see our guide to a laptop keyboard that isn’t working.
Membrane and office keyboards
Drain, blot and dry thoroughly. Some keycaps pop off for cleaning, but membrane layers are hard to clean inside. If keys stay sticky after drying, a cheap office keyboard is often more practical to replace than repair.
What not to do
- Don’t use a hair dryer, oven or radiator to speed drying.
- Don’t put it in rice. It isn’t a proven way to dry electronics, and starch dust or grains can get inside.
- Don’t spray cleaner directly onto the keyboard.
- Don’t power it on to check if it still works before it’s fully dry.
Sticky keys after drying
Sugar and milk dry into a sticky film. On mechanical keyboards, remove the keycap, clean around the switch with isopropyl alcohol on a swab, and press the switch repeatedly to work it loose. If a switch is still sticky, replace it on a hot-swap board or open it to clean it. On laptops, sticky keys after a spill usually need a professional clean.
Prevent the next spill
- Keep drinks on the far side of your mouse, or use a lidded mug.
- Put a keyboard cover on when you step away.
- Remember that most keyboards aren’t sealed. See are keyboards waterproof? for what spill-resistant ratings really mean.
FAQ
Can a keyboard survive a coffee spill?
Often, yes, especially mechanical keyboards, if you cut the power quickly and let it dry completely before using it.
How long should a keyboard dry after a spill?
At least 24 hours, and 48 hours for laptops or larger spills. Make sure it’s fully dry inside before powering on.
Should I put my keyboard in rice?
No. Leave it upside down in open air instead, so no rice dust or grains get inside.
Can I clean coffee off with water?
Wash removable keycaps in water. For the keyboard itself, use isopropyl alcohol on a swab, which evaporates quickly.
Is my laptop ruined after a spill?
Not necessarily. Shut it down immediately, keep it upside down, and have it checked if the spill was large.
Final thoughts
After a spill, the first minute matters most: cut the power, turn it upside down, and blot. Then let it dry completely before using it again. Mechanical keyboards usually recover with a proper clean; laptops deserve more caution and sometimes a professional check.

Experience is what matters at the end!!
Hi! This is Jacob Jay – founder of Keyboardgear.com! From childhood to adulthood, I’ve always remained passionate about IT, and the revolution in this industry, especially gaming on the PC can’t go out of my way. Since I’m an enthusiastic gamer, and I love to experience various gaming accessories, particularly mechanical keyboards, that really boost my gaming adventure manifolds. So, my nerve cells hit me to transfer my experiences into word form and share with others to identify the ideal keyboards perfectly fit for their gaming modes.
I know very well how hard it is to find the high-quality items available on the internet that ought to be exactly the same as seen as on the screen. But the counterfeiters have ruined the user’s trust. As I have passed all such situations, I’m obliged to deliver the genuinity and express the same as what I am saying.
So, now, I’m working on the mission to provide very helpful and frankly but trustworthy reviews and guides about various mechanical keyboards, mouses, and other gaming accessories as per my personal experiences and sound knowledge.