Windows
A keyboard collects a year of lunches: crumbs under the keys, dust in the rows, and a shine on the letters you use most. Cleaning it is a ten-minute job and perfectly safe — as long as you remember the one rule that governs everything below: keyboards and water are enemies, so the cloth is barely damp, never wet.
Switch the computer off. If your keyboard has a cord, unplug it; if it is wireless, switch it off or take a battery out. On a laptop, shut the computer fully down — a half-awake laptop wakes up mid-clean and “types” whatever your cloth presses.
Hold the keyboard upside down over a bin and tap its back gently. Loose crumbs and dust fall out — more than you expect. For a laptop, tip the whole machine at an angle, keyboard facing down-ish, and tap the back of the screen lid softly.
Work along the rows with a soft brush — a clean, dry paintbrush or an old toothbrush — to sweep out what the shake loosened. A can of compressed air does the same job faster: short bursts, nozzle held at an angle, never one long blast straight down (that just pushes the grit deeper).
Dampen a soft cloth — the microfibre kind that comes with glasses is ideal — with water, then wring it until it is almost dry. Wipe across the key tops, and use a cotton bud, just as barely-damp, for the gaps between keys. For greasy shine or a germ-clearing pass, use a cloth touched with a little rubbing alcohol (the chemist’s kind) instead of water: it cuts grease and dries in seconds. Whatever you use, put the liquid on the cloth, never spray or pour it onto the keyboard.
Never: soak a keyboard, hold it under a tap, or use bleach or kitchen sprays. (A rare few desktop keyboards are sold as washable and say so on the box — if yours does not say it, it is not.) A vacuum cleaner is a poor tool here too: the suction can lift a loose key cap clean off, and a brush does the job better.
If a drink went into the keys, the wipe above fixes the surface — but sugar dries sticky inside, and a key that still feels gummy a day later is telling the truth. On a separate desktop keyboard, a badly gummed board is usually cheaper to replace than to rescue. On a laptop, sticky or dead keys are a workshop job — and our tip Some of the keys on my keyboard stopped working walks the checks that tell a dirty keyboard from a worn-out one, including how crumbs alone can silence a key.