When and why you need to replace your keyboard

A laptop keyboard fails in two ways: keys stop responding or feel mushy, or the whole keyboard assembly is damaged by liquid or impact. If only one or two keys stick, cleaning under them with compressed air sometimes works. If multiple keys are dead, the keyboard circuit has failed and replacement is the only fix.

Replacing a laptop keyboard is simpler than most people think — it usually takes 15 to 45 minutes and costs between $40 and $150 in parts, depending on your model. You do not need special training or tools beyond a small Phillips screwdriver and a plastic pry tool (a guitar pick works). The hardest part is finding the exact keyboard model for your laptop, because every manufacturer uses different part numbers.

Key Takeaways

  • Find your exact laptop model number (usually on the bottom or in System Settings) before ordering a replacement keyboard, because part numbers vary by manufacturer and region.
  • Most laptop keyboards are held down by a few screws under the bezel or behind the screen hinge, and the keyboard plugs into a ribbon cable underneath.
  • Disconnect the battery before you start work to avoid electrical damage if you accidentally touch the wrong component.
  • Take a photo of the ribbon cable connection before you unplug it so you know how to reconnect it the same way.

Finding the right replacement keyboard for your laptop

Your laptop's keyboard part number is not the same as your laptop model number. A Dell XPS 13, for example, might use one of five different keyboards depending on the year and region it was sold in. Ordering the wrong one means the keys will not line up or the connector will not fit.

Start by finding your exact laptop model. On Windows, open Settings, go to System, then About — look for "Model" or "Device name". On Mac, click the Apple menu, select About This Mac, and note the "Model Identifier". Then search "[your exact model] keyboard replacement" on the manufacturer's support site or on parts retailers like iFixit, Amazon, or eBay. These sites list the correct part number and show photos of the keyboard so you can confirm it matches yours.

Write down the part number before you order. When the keyboard arrives, compare the connector type and key layout to your current keyboard — if they do not match, contact the seller before you open the package.

Preparing your laptop and gathering tools

Shut down your laptop completely and unplug the power adapter. If your laptop has a removable battery, take it out. If the battery is built in (most modern laptops), just leave it unplugged for a few minutes — this drains residual power and protects components if you accidentally touch the wrong wire.

Gather a small Phillips screwdriver, a plastic pry tool (a flathead screwdriver works but risks scratching plastic), and a clean cloth. Set up on a flat surface with good lighting. Keep the old keyboard nearby so you can refer to it if you forget how something connects. Take a photo of the ribbon cable connection with your phone before you unplug anything — this is your safety net if you get confused during reassembly.

Removing the old keyboard

The keyboard is usually held in by three to six small screws. On most laptops, these screws are hidden under a thin plastic bezel that runs along the top of the keyboard. Use your plastic pry tool to gently lift this bezel away from the screen — start at one corner and work along the edge. The bezel usually clips in place, so it will pop off with gentle pressure. Do not force it or you will crack the plastic.

Once the bezel is off, you will see the screws. Remove each one and place them in a small container so you do not lose them. Some laptops hide screws under rubber feet or stickers — if you see adhesive feet around the keyboard, peel them back carefully and check underneath.

After the screws are out, gently lift the keyboard away from the laptop. You will see a ribbon cable attached to the bottom. This cable is fragile — do not yank it. Look at how it connects: most ribbon cables slide into a socket with a small latch or clip. Gently push the latch away from the cable to release it, then slide the ribbon out. If there is no visible latch, the cable may be glued in place — in that case, gently wiggle it side to side as you pull, or use a plastic tool to carefully lift one edge of the socket.

Installing the new keyboard

Before you touch anything, compare the new keyboard's ribbon cable to the old one. The connector should be the same size and shape. If it is not, you ordered the wrong keyboard — stop and contact the seller.

Slide the new keyboard's ribbon cable into the socket. It should slide in smoothly without force. Once it is fully inserted, push the latch or clip back toward the cable to lock it in place. If there is no latch, the cable is held by friction alone — that is normal.

Position the keyboard in the laptop so the screw holes line up. Insert each screw and tighten them gently — do not overtighten or you will crack the plastic frame. Snap the bezel back into place along the top edge. It should click into position without gaps.

Testing the new keyboard and troubleshooting

Plug in the power adapter and turn on your laptop. Test every key, including the function keys and any special keys like volume or brightness. On Windows, open Notepad and type a sentence to confirm all keys work. On Mac, open TextEdit and do the same. Pay special attention to keys that were broken on the old keyboard — they should now respond when ready.

If some keys do not work, the ribbon cable may not be fully seated. Power off, unplug the adapter, and check the connection again. Make sure the cable is pushed all the way into the socket and the latch is fully closed. If the cable looks bent or damaged, you may have a defective part — contact the seller for a replacement.

If the keyboard works but feels loose or rattles, check that all screws are tight and the bezel is fully clipped in. If keys feel different from before (softer or harder), that is normal — different keyboard models have different key travel and feel.

When to take your laptop to a technician instead

If your laptop has a keyboard that is soldered directly to the motherboard (rare but possible on some ultrabooks), replacement requires removing the entire motherboard and is not a home repair. If you are uncomfortable opening your laptop or the bezel will not come off without cracking, a repair shop can do the work for $80 to $200 in labor.

If liquid damage caused the keyboard failure, the problem may extend to the motherboard underneath. A technician can inspect for corrosion before you reassemble everything. If you spilled liquid, let the laptop dry completely (at least 48 hours) before powering it on again.

Frequently Asked Questions

Can I replace just one key instead of the whole keyboard?

Individual keys are sold as replacements, but only if the key cap is cracked or the scissor mechanism is broken. If the key does not respond electrically, the problem is in the keyboard circuit underneath, and replacing one key will not fix it. You need a new keyboard assembly.

What if I lose a screw during the replacement?

Laptop screws are small and straightforward to lose. If you drop one, search the floor carefully with a flashlight. If you cannot find it, you can reassemble without it — the keyboard will stay in place with the other screws. Order a replacement screw from the parts retailer or a hardware store with a magnifying glass to match the size.

Do I need to install drivers for the new keyboard?

No. Laptop keyboards use the built-in keyboard driver in Windows or macOS, and the new keyboard will work when ready after you plug in the ribbon cable. You do not need to read or install anything.

How long does a replacement keyboard last?

A replacement keyboard should last as long as the original — typically five to seven years of normal use. If you spill liquid on it or drop the laptop, it will fail sooner. Keeping your laptop on a clean surface and using a keyboard cover reduces wear.

Can I use a keyboard from a different laptop model?

Not reliably. Even if the connector looks the same, the screw holes and key layout will not match your laptop. The keyboard may fit loosely or not fit at all. Always use the exact part number for your model.