Electrical wall sockets can stop working for a variety of reasons. Many times someone may assume the socket is bad and replace it, only to find out that doesn't fix the problem. Proper troubleshooting of a wall socket can help you determine if the socket is bad or if you have another issue.
Determine if the lamp or other electrical item that won't work is properly plugged into the outlet. If that doesn't fix the problem, plug the item into another outlet to make sure it is still functioning.
Investigate to determine if a switch somewhere else in the room that controls the outlet is turned off. If this is the case, turn it on. The switch may control only one of the receptacles in the outlet.
Check the breaker or fuse that is assigned to the circuit on which the outlet resides. Reset the circuit if it is tripped. Replace any blown fuses.
Shut off the breaker for the outlet's circuit and unscrew the cover plate. Test the wires with a voltage tester to make sure none of the wires are still hot. If the wires are still hot, the outlet is on a different circuit and another breaker controls it. Find the proper circuit by turning off each breaker one after the other and checking the wires until they are no longer hot. Check the connections to the outlet and make sure the wires are securely fastened.
Turn on the breaker for the outlet. Test the wires with the voltage tester to make sure that they are hot. If not, there may be a problem with the wiring or with the breaker.
Replace the outlet if you found no other problem while troubleshooting.