Turn off the power off. Open the electrical panel and turn off the appropriate breaker. If unsure of the breaker configuration, cut power to the house by flipping all the breakers off. There must be no current flowing through the switch being replaced.
Test for electrical current. Place a circuit tester into the electrical outlet closest to the switch. The circuit tester looks like a cordless electrical plug. On the backside of the tester is a small bank of LED lights. If the electricity is off, the LED lights will remain dark. If any current is passing through the outlet, the LED lights will be lit. Recheck the breakers if the tester's lights are lit.
Remove the face plate. Using a standard screwdriver, remove the switch plate. If the plate has been painted over, use a utility knife to separate the plate from the paint. Lightly cut a line around the edge of the switch plate to separate it from the painted wall.
Remove the switch. The switch is held in place by two set screws located on the front of the metal switch box. Use a standard screwdriver to remove the set screws. Gently remove the switch from the box it is mounted to. Pull the switch out far enough to expose the wiring.
Disconnect the wiring. Place a small piece of masking tape next to each terminal on the replacement switch. As each wire is removed from the old switch, write down the disconnected wire's color and position on the replacement switch. Use a screwdriver to loosen the threaded terminal post. Gently pull the wire off of the post. Write down the wire's color and position on replacement switch. If a red wire is removed from the old switch, write down its color and attachment point on the replacement switch. Repeat this process for each wire.
Cut and strip the plastic/rubber shielding that covers the wiring. Cut the unshielded wiring off with a pair of wire cutters. Strip the shielding off of each cut wire with wire strippers, removing about 3/4-inch of shielding from each wire.
Attach the wiring. Turn the terminal screw counterclockwise until the bare wire can be wrapped around the threaded terminal post. Use a pair of needle-nose pliers to bend the bare wiring into a "U" shape. Slip the bent wire around the appropriate terminal post. Tighten the terminal screw until the wire is held firmly in place. Repeat the process for each wire.
Mount the switch. Insert the switch into the metal box. Put the set screws back in place. Replace the face plate and its mounting screws. Turn the power back on.