On the basis of a predetermined condition, a power conversion device performs switching between an HM control mode in which a first period during which a switching element for an upper arm and a switching element for a lower arm are turned on respectively in different phases and an electric current is supplied from a direct-current power source to a motor and a second period during which either the switching element for the upper arm or the switching element for the lower arm is turned on in all phases and torque is maintained by energy stored in the motor are alternately formed according to the electrical angle, and a sinusoidal PWM control mode in which the switching elements are turned on according to the pulse width determined on the basis of the result of a comparison between a sinusoidal command signal and a carrier wave and the electric current is supplied from the direct-current power source to the motor.