The purpose of commutators in a direct current (DC) motor is to reverse the direction of the current after every half rotation.