Pulsewidth-modulated (PWM) inverters are used more and more to operate electrical machines and to interface renewable energy systems with the utility grid. However, there are abundant high-frequency harmonics in the output voltage of a PWM inverter, which increase the iron losses and result in derating of the machine or transformer connected to them. Predicting the iron losses caused by the PWM supply is critical for the design of electrical machines and transformers operated by PWM inverters. These losses are primarily attributed to eddy-current loss caused by the PWM supply. In this paper, after analyzing the harmonic components of PWM voltage, we derive the effects of different parameters of PWM switching on the eddy-current loss. We compare the iron losses modeled with the proposed analytical methods on a three-phase transformer, a dc motor, and an induction motor with the results of time-stepping finite-element analysis and experiments. We provide detailed equations for the prediction of iron losses. These equations can be directly applied in the design and control of PWM converters and electric motors to improve energy efficiency in electrical machines and transformers operated from PWM converters.