How can I tell when an outlet isn’t safe?

If it no longer holds a plug snugly, if any parts of the outlet are broken, or if the outlet is hot to the touch, replace the outlet.