A relay is an electrically operated switch. They usually use an electromagnet (coil) to operate their internal mechanical switching mechanism. When a relay contact is open, it will turn on the power for a circuit when the coil is energized. The example relay diagram below shows how a relay works.