A transformer is an electrical device that is used to transfer electrical energy between two or more circuits through electromagnetic induction. Its primary role is to change the voltage level of an alternating current (AC) electrical system, either stepping up the voltage for long-distance transmission or stepping down the voltage for safe use in homes and businesses.