How to Clean a Keyboard

Follow these steps to remove crumbs and other stuck-on debris to keep your keyboard clean and germ-free.
Deirdre Mundorf Avatar
how to clean a keyboard - hand cleaning keyboard

We may earn revenue from the products available on this page and participate in affiliate programs. Learn More ›

A computer keyboard is one of those electronic devices that rarely gets cleaned. However, if you’ve taken a close look at your keyboard, you’ll likely notice crumbs and debris between the keys. There may even be a sticky residue left behind that is starting to impact your ability to type. Computer keyboards—particularly those that are shared by multiple people—should be given a quick cleaning at least once a week. In fact, according to research conducted by the University of Arizona, the average desktop/keyboard area can have up to 400 times more bacteria than some toilet seats. Follow the steps below to learn how to clean a keyboard properly.

Tools & Materials may earn a commission from purchases made through these links.

Project Overview

Working Time: 15 to 20 minutes
Total Time: 15 to 20 minutes
Skill Level: Beginner
Estimated Cost: $5 to $50


Keyboards are sensitive electronic devices. For this reason, you’ll want to be careful to avoid damaging your keyboard when cleaning it. Never submerge a keyboard or place it in the dishwasher to clean it. Consult the manual for your keyboard before cleaning it. Some manufacturers may include special directions or point out areas that should not be cleaned, such as special displays or RGB lighting.

RELATED: 30 Gaming Room Ideas for the Perfect Streaming Setup

STEP 1: Unplug the keyboard from the computer or remove the batteries.

Before you start to clean your keyboard, unplug it from the computer. If you have a wireless keyboard, remove the batteries. For laptop keyboards, make sure the laptop is turned off. Move the keyboard to a separate work area away from your computer to keep the dust and crumbs on the keyboard from getting into the components of the computer and causing additional problems.

how to clean a keyboard - black keyboard with mouse

STEP 2: Turn the keyboard upside down and tap it to loosen and release crumbs.

Lay out a plastic tablecloth or a few pieces of newspaper over a workspace, and flip the keyboard upside down over the paper. Some debris will fall out right away, but other crumbs will likely remain trapped inside the keyboard. Give the back of the keyboard a gentle tap or two to dislodge some of this debris.

Whether you want to clean a mechanical keyboard, ergonomic keyboard, or laptop keyboard, you want to avoid shaking the device. Doing so can damage the internal components and prevent the keyboard—or computer—from functioning properly.

Closeup of potato chips on a laptop keyboard

STEP 3: Use a keyboard cleaning brush to remove leftover debris.

Turning the keyboard upside down will remove a lot of the gunk, but not all of it. A computer keyboard cleaner brush can help you loosen and remove more of the caked-on dust and crumbs. Take care to brush the spaces between each key. If you do not have a keyboard cleaning brush, a new toothbrush can also work.

A keyboard vacuum can also help pull out more debris. However, you’ll want to avoid using a household vacuum, as the more powerful suction could potentially pull off a keyboard’s pop-off keys.

RELATED: 14 Ways You Never Thought to Use Q-Tips

how to clean a keyboard - keyboard with brush

STEP 4: Spray the keyboard with compressed air.

Next, you can clean a keyboard with compressed air to remove more hidden debris. Compressed air cans come with a narrow dispenser that works to provide a powerful and target burst of air to dislodge debris. When working with compressed air, holding the can at an angle less than 40 degrees is important to keep refrigerant from being released. You’ll also want to complete this step outside or over a covered surface, as it is likely to send dust and crumbs flying.

After spraying the compressed air, flip the full-size or mini keyboard upside down again and give it a few more taps. The compressed air may have loosened more debris that will drop out now.

how to clean a keyboard - cleaning with compressed air

STEP 5: Clean the space between the keys on the keyboard.

While your keyboard is likely much cleaner now, there may still be some gunk stuck between the keys. A cotton swab, sticky note, or cleaning gel can all help to clean a keyboard that is sticky. You can work these tools between and over the keys to remove more gunk and grime that could be causing the keys to stick when you type. If you choose to use cleaning gel, keep in mind that it can leave behind an oily residue. Testing the gel on a small area of the keyboard first may be a good idea.

A laptop keyboard being cleaned with a cotton swab

STEP 6: Clean the keyboard keys.

Whether you’re looking for how to clean a laptop keyboard or u model, the final step is to clean the keys. However, the process for cleaning keyboard keys can vary based on the type of keyboard you have. Some models have removable keycaps that can be taken off and soaked in soapy water to remove grime and sticky residue. If your model has removable keys, be sure to check with the manufacturer’s cleaning recommendations before placing them in water. After cleaning the keys, leave them out to dry thoroughly before snapping them back into place. It may also be a good idea to take a picture of the keyboard before taking the keys off so you know exactly how to put everything back together.

You can use alcohol wipes, screen wipes, or microfiber cloths dampened with rubbing alcohol to clean non-removable keys. Avoid using straight liquids to clean the keyboard, as they could damage it.

how to clean a keyboard - cleaning laptop keys

Final Thoughts

The best way to clean a keyboard may vary slightly depending on the specific model you have. Following the steps outlined above will help you remove dust and other debris from your laptop or standalone computer. Keeping your keyboard clean will not only help it look nicer and limit the spread of germs, but it will also prevent the keys from sticking and keep it working properly.

RELATED: 18 Home Office Items for Optimal Ergonomics and Productivity