The primary purpose of a transformer is to change the voltage level in an AC circuit, either stepping it up or stepping it down.