How Do Door Locks Work? | The Mechanics Inside

Door locks work by aligning internal pins or tumblers so a cylinder can rotate and move a bolt into or out of a strike plate.

Whether you’re rekeying a front door or just curious what happens when you turn that key, understanding how door locks work comes down to a few moving parts doing precise work. Most residential locks use spring-loaded pins that block rotation until the right key lifts them to a single line, letting the bolt slide free. Here’s what happens inside that metal casing.

The Two Essential Parts Of Every Door Lock

A lock has two halves that work together. The cylinder and lock body sit in the door itself; the strike plate is the reinforced metal receiver mounted in the door frame. When locked, the bolt extends from the cylinder into the strike plate, physically blocking the door from swinging open.

Turning the correct key rotates the cylinder’s inner plug, which moves a cam. That cam drives the bolt forward into the strike plate to lock, or pulls it back to unlock. Nothing else matters if these two halves don’t line up.

What Happens Inside When You Turn The Key

The most common design is the pin-and-tumbler lock, and its operation is precise. Here’s the exact sequence:

  • Insert the key into the keyway — the slot in the cylinder.
  • Key cuts lift the pins upward against their springs, each to a specific height matching that pin’s length.
  • The shear line clears when every pin stack aligns perfectly between the plug and the housing.
  • The plug rotates once that line is clear, turning the cam.
  • The cam moves the bolt — retracting it to unlock or extending it into the strike plate to lock.

A key that almost fits won’t work. If even one pin sits at the wrong height, the plug cannot turn because the pin blocks rotation at the shear line. Correct alignment of every single pin is mandatory, not optional.

Mechanical And Electronic Locks Are Different Machines

Not all locks use pins. Older rim locks use a key to push a tumbler out of the way. Disc-tumbler locks swap pins for movable discs, wafer locks use flat wafers, and cam locks rotate a simple arm. All share the same logic: the correct key clears a mechanical blocker so something can turn.

Electronic door locks replace the key with current. A keypad, fob, RFID card, fingerprint reader, or Bluetooth credential sends a signal to a controller, which verifies it and fires an actuator or solenoid to move the bolt. The source of motion is electricity, not your wrist. These locks also need power and an authentication pathway — if the batteries die or the wiring fails, the hardware doesn’t move.

What To Know Before Buying

Security depends on clean alignment. A bolt that doesn’t fully seat in the strike plate, worn internal parts, or a poorly installed frame all undermine an otherwise solid lock. For electronic models, confirm the power source and credential type before you buy, since features vary by model.

If you’re ready to upgrade, our tested roundup of the best door locks for home breaks down which models actually hold up, based on hands-on testing.

Lock Type Internal Mechanism Typical Use
Pin-and-tumbler Spring-loaded pins blocking the plug Most residential doors
Rim lock Key presses a tumbler aside Older and surface-mounted doors
Disc-tumbler Rotating discs instead of pins Cabinets and some padlocks
Wafer lock Flat wafers aligning with key profile Desks, toolboxes, file cabinets
Cam lock Rotating arm that turns a fastener Mailboxes, drawers, utility panels
Electronic Motor or solenoid driven by current Keypad and smart deadbolts

One of the most common mix-ups is confusing the bolt with the strike plate. The bolt moves; the strike plate is the fixed receiver. Another is assuming all locks work the same way — the five mechanical types above each use a different internal design. And if you hear someone say “any key will work if it’s close,” they’re wrong. Explain That Stuff explains how precise pin alignment is what keeps the plug from turning.

Whether you go mechanical or electronic, the principle holds: something must align or release inside, and then the bolt must reach the strike plate. A lock that fails either step is just decoration.

FAQs

Why Does My Key Stop Working Sometimes?

Worn pins, a bent key, or debris inside the keyway can all stop the pins from reaching the correct height at the shear line. If the bolt also fails to fully seat in the strike plate, the lock won’t secure the door even when the key turns.

Are Electronic Locks Harder To Break Than Mechanical Ones?

Not automatically. Electronic locks remove the keyhole but rely on power and an authentication pathway, which introduces battery or wiring failure points. Mechanical locks depend on physical alignment of pins. Both can be defeated; the best choice depends on your door and threat model.

Can One Key Work For Multiple Locks?

Yes, if all locks are keyed to the same pin configuration. That is how a single house key opens the front, back, and garage doors. A locksmith can rekey locks so one key operates them all.

References & Sources

Please use a real email you check. If it's fake or mistyped, your message won't reach us and we can't reply — wrong addresses are rejected automatically.