
Well, let's assume you've got a regular Kwikset deadbolt, with five pins. If you've got a pinning kit, terrific. If not, you're pretty much stuck working with the pins you find inside that lock, or that you can scrounge from other locks of the same brand. There are a few tools that will help you, as well:
A pair of tweezers. . .moving pins around can be tricky for fingers.
A plug follower. . .absolutely necessary. It can be a wooden dowel, a metal rod, plastic tube, a pen, anything that's the exact same diameter as the cylinder. It has to slide in perfectly as you remove the cylinder from the lock body, so the top pins and springs don't go flying out. Make sense?
Shims. . .flat pieces of very thin, weak metal. Necessary only if you don't have a key to that lock. We'll cover that later. If you're going to shim, you also need a blank key for that lock.
Pins. . .well, yeah.

The new key you want the lock to match.
Anyways, let's assume you've taken your deadbolt off the door and have it sitting on the table in front of you. Forget about the back half of the lock, the part with the thumbturn. Set it aside. Take the front half of the deadbolt. Now, looking at the back of the cylinder, you'll see the tailpiece sticking up off it. Down where the tailpiece meets the cylinder is the "endcap", the part that screws down/on to hold the cylinder in the lock body, and the tailpiece on the cylinder. Clear so far?
Good. . .now you need to remove the tailpiece and endcap. On some, this simply means unscrewing the endcap. Sometimes, there will be a tiny, springloaded metal rod sticking up from the cylinder into the endcap, preventing it from unscrewing. Take a paper clip or something thin and press the rod down out of the way while you unscrew the endcap. Sometimes there may be a thin, rounded-"E" or "C" shaped clamp around the tailpiece instead. Use a pair of needle-nose pliers to remove this clamp, then take off the tailpiece too.
Now that the back is off, the only thing holding the cylinder in the lock body is the pins, blocked by the shear line. So you take the key, and insert it into the lock. *DO NOT* pull the cylinder out.


(The reason you turn the key 90 degrees to the right is so the top pins don't drag across the bottom pins' holes. It decreases accidental jamming.)
Now you've got the cylinder, with the five bottom pins still in it. Remove them one at a time, keeping your finger over all the remaining pins each time so they don't fall out and get mixed up. Always keep the pins in order.
Now, if you wanted to match the lock to a new key, you would insert that new key into the cylinder, and match new pins to it. The right pins for each hole will stand perfectly flush with the top of the cylinder (where the shear line would be). Not too tall, not too short. When you re-insert the cylinder, if it jams at all or sticks when it turns, you probably put an incorrect pin in one of the holes. It can be tricky, the differences in height are very small. When the right pins are in all five holes, your finger should run smoothly across the surface without bumping at all.
Let's say you've got all five new pins matched perfectly to the new key. With the key still in the cylinder, you would now place the cylinder back against the follower, and slowly press it back into the lock body, never breaking contact. (And remember that 90 degree angle!) When the cylinder is all the way in, you can remove the follower. Try turning the key from side to side, to make sure the cylinder isn't sticking. If it is, use the follower to remove it again, and double-check your pins.
If the cylinder is turning just fine, though, then place the tailpiece back on the cylinder, and the endcap or clamp to keep it in place. Re-assemble the lock to the door, and you're done! Always test it a few times with the new key, though, to make sure it's working.
Now. . .what happens if you accidentally slip with the follower, or forget it entirely, and all the top pins and springs fly out? Well, all the top pins are the same length, so it doesn't matter what order they go back in. Insert your follower into the lock body, covering three of the holes, leaving two uncovered. Using tweezers, place a spring in the second, still-uncovered hole (the one farther in). Then place a top pin in that hole. This is the really horrid part. . .those pins will try to roll all over the place, and you will probably get really frustrated until you get the hang of it.

Now, turn the lock around, and keep sliding the follower forward until the first three holes are now uncovered, but the two with springs and pins are covered. Place your spring and pin in the third hole in, then the second, then the first, covering each with the follower as you go. Once the pins and springs are in place and the follower is covering them all, you're ready to go again!
(The reason you do two holes, then the other three, is because it's darn near impossible to reach all the way down the cylinder to do the farthest hole from you, and work your way out. It's just easier this way, do the ones in the middle, then the ones easier for you to reach near the outside.)
Anyways. . .hmmm. . .ah, right, shims! These are not the same as padlock shims, although the metal is similar. They are just curved rectangles of very thin, delicate metal. If you do not have a key to the lock you wish to rekey, you could just try to pick it. Or, once you have the endcap and tailpiece removed, you can try to shim it, which requires a blank key. Insert the blank key in the lock, and then gently slide your shim into the back, between cylinder and body, at the shear line. The blank is pushing all the pins as high as they can go, right? Now, very gently (you will probably bend the shim a few times, just don't do it too much), with one finger, press the shim into the lock. It will be pressing against the fifth pin. As you press the shim, very slowly slide the key back, allowing the fifth pin to drop. With luck, the shim will slide in between the bottom and top pin as they move downward. If it doesn't, push the key back in and try again. The shim is essentially taking the place of the shear line created by the correct key.
Now, slide back the key a little more, while still gently pressing the shim against the fourth pin. With luck, once again, it will slide between bottom and top. Keep going like that, little by little, until you've got the shim through all five pins. The shim may try to slide from side to side, do not let it. If it slides too far sideways, it will slip out from between the pins and you have to start over. Once the shim has properly slid through all five, turn the key to the right 90 degrees, and remove the shim. Place your follower against the back of the cylinder, and remove it the same way I described earlier.

Well, that's pretty much basic rekeying. If you are doing something like a key-in-knob lock, you may find that the entire cylinder and cylinder housing come out together from the knob, in one piece. Mortise cylinder locks will usually have tailpieces that screw on to the back of the cylinder with one or two tiny screws. Most of it's intuitive, just study it carefully and figure out how it works.
If you're ever interested in trying that whole "removing pins from a lock so you can learn to progressively pick one more at a time", just remove the cylinder same as you would normally. Then slide the follower forward slowly and allow the top pin and spring to fall out of each hole you don't want to have pins in. Remove the corresponding bottom pins from the cylinder as well, then put it all back together.
I hope this was understandable, and that you all enjoyed learning it. If there are any questions, feel free to e-mail or IM me. Good luck, and happy picking!
