An electronic device includes a memory storing profile information, at least one first electrode, at least one second electrode, and a processor connected to the at least one first electrode and the at least one second electrode. The processor is configured to determine a frequency of at least one signal for measuring body composition, based on the profile information, output a synthesis signal obtained by synthesizing the at least three signals to a body of the user through the at least one first electrode, wherein the synthesis signal includes a signal corresponding to the determined frequency and the at least three signals have different frequencies, receive the synthesis signal passing through the body of the user, through the at least one second electrode, measure body impedance of the user based on the received synthesis signal, and measure the body composition of the user based on the body impedance.